Questions tagged [partial]

Existing only in part; incomplete.

Existing only in part; incomplete.

1478 questions
22
votes
5 answers

Partial render in HTML/JavaScript

I have some HTML files, and each one of them I want to partially render in another HTML file, for example header.html and footer.html in order to observe DRY concept. HTML files should look like this:
Afshin Mehrabani
  • 33,262
  • 29
  • 136
  • 201
21
votes
4 answers

Using binding.pry in Rails app's view or partial

Pry is quite amazing in my R3 app. But any chance I can use <% binding.pry %> in a view or a partial like I did previously with <% debugger %> This doesn't seem to work. Thanks.
valk
  • 9,363
  • 12
  • 59
  • 79
20
votes
6 answers

How to render partial.js in rails 3

Using rails3 - I have a project with many tasks. I want to use javascript to build the UI for each task. I figured I could display those tasks on the projects show page by rendering a javascript partial for each. I can't get 'tasks/show' to see…
Julian Mann
  • 6,256
  • 5
  • 31
  • 43
19
votes
11 answers

What are practical uses for STL's 'partial_sum'?

What/where are the practical uses of the partial_sum algorithm in STL? What are some other interesting/non-trivial examples or use-cases?
Matthieu N.
18
votes
2 answers

Workaround in mysql for partial Index or filtered Index?

I am using mysql db. I know postgresql and SQL server supports partial Indexing. In my case I want to do something like this: CREATE UNIQUE INDEX myIndex ON myTable (myColumn) where myColumn <> 'myText' I want to create a unique constraint but it…
Andrews
  • 895
  • 3
  • 15
  • 30
18
votes
2 answers

link_to and remote => true + jquery : How? Help?

Im trying to make an "Users" link on the index of my rails website so that it shows the registered users (User.all) BUT i want that to appear on the right part of the website, as a partial, in a div without loading the whole page from the start. I…
Filippos
  • 221
  • 1
  • 3
  • 4
18
votes
6 answers

Missing partial modifier on declaration ..another partial declaration of this type exists". I'm a beginner and just following the book

I'm a beginner and I'm doing an exercise following a book. Below is my code and i got this "Missing partial modifier on declaration of type 'Windowsform.Form1'; another partial declaration of this type exists". What should i do? My code is as…
user1742237
  • 189
  • 1
  • 1
  • 3
17
votes
7 answers

ASP MVC View Content as JSON

I have a MVC app with quite a few Controller Actions that are called using Ajax (jQuery) and return partial views content which updates a part of the screen. But what I would rather do is return JSON something like this. return Json(new { …
Craig
  • 36,306
  • 34
  • 114
  • 197
17
votes
1 answer

Jade include with parameter

In an older version of Jade I was able to include partials and pass variables into them like this: !=partial('partials/video', {title:video.title, artist:video.artist}) now the partial connotation does not exist any more. How do I achieve the same…
suMi
  • 1,536
  • 1
  • 17
  • 30
16
votes
1 answer

jQuery: Finding partial class name

I want to see if an
  • has a certain class, the catch is though that they all are unique but all contain a constant string of 'unqID'. I want to check to see if the
  • has a class that contains this string and if it does not, add the new class…
  • pn03
    • 289
    • 1
    • 3
    • 9
    16
    votes
    2 answers

    add partial file to existing form file

    I have a Window Form App project. At the moment all of my code is in Form1.cs file which is the default file. Now I have about 1300 lines of code in this single file. I want to break down this one file code into several files and I want to use the…
    user1903439
    • 1,951
    • 7
    • 19
    • 29
    16
    votes
    3 answers

    Yii difference between rendering functions

    I sometimes get messed up by the three rendering methods: Controller::render() Controller::renderPartial() Controller::renderFile() Please could you explain. Thank you!
    Nam G VU
    • 33,193
    • 69
    • 233
    • 372
    16
    votes
    5 answers

    HTML5 video - playing only a portion of a video

    Is there some straightforward technique to play only a certain part of a HTML5 video? For example in a 30 second clip I would like to play only the part 5-20 sec. Additionally the rest of the video should not be accessible from the UI at all…
    calle
    • 848
    • 1
    • 5
    • 7
    15
    votes
    5 answers

    Rails AJAX: My partial needs a FormBuilder instance

    So I've got a form in my Rails app which uses a custom FormBuilder to give me some custom field tags <% form_for :staff_member, @staff_member, :builder => MyFormBuilder do |f| %> [...] <%= render :partial =>…
    Gareth
    • 133,157
    • 36
    • 148
    • 157
    15
    votes
    2 answers

    Android: How to get a custom view to redraw partially?

    I have a custom view that fills my entire screen. (A piano keyboard) When a user touches the key, it causes invalidate() to be called and the whole keyboard gets redrawn to show the new state with a touched key. Currently the view is very simple,…
    Peterdk
    • 15,625
    • 20
    • 101
    • 140
    1 2
    3
    98 99