javascript - Getting the URI used to load a div on a page? -


I have jQuery. There is a div on the PHP-generated page loaded by the Load () function. This section has a long list which is endorsed (link to page 1, 2, 3 ... 25, etc.). I would like to write a function which will preserve the variable in the 'Search' portion of the URI (which is to say at the end of the URI: Foo = 1 & bar = pancakes) and a & amp; At the end of X, however, to do this, I need to recover the current URI which loads the div from that div.

window.location.search clearly receives information only from the parent page, so there is no help .js files are loaded statically, so I set the variable I can not stick to PHP in the middle of javascript. I can not even take the paging link in the original page, because I need the number of pages to change the number of entries in the list. There is no harm in how I can accomplish this task. Any suggestions would be greatly appreciated.

Edit: The link is controlled by jQuery to load the device with all the new information - hence the .load ()

$ _GET variable:

  function getvars_to_url_fragment () {loop directly through $ ret 

= ""; $ Amp = ""; Get the foreign currency ($ _ = $ k => $ v) as {$ ret. = $ Amp.urlencode ($ k). "=". Urlencode ($ v); $ Amp = "& amp;" ; } Return $ ret; }


Comments