URL via javascript into CodeIgniter |
[eluser]Doncqueurs[/eluser]
Hi, I ran into a little problem and couldn't really find an answer in this forum. It seems like there has been a closely related issue a year ago, but unfortunately that didn't help me to solve the problem. I try to do the following. With this piece of javascript I would like to add url and sitename to my application. Quote:java_script:location.href='http://localhost/index.php/bookmarks/add/'+encodeURIComponent(location.href)+'/'+encodeURIComponent(document.title) This results in the following URL: Quote:http://localhost/index.php/bookmarks/add...0framework On the receiving end I have this script: Quote:<?php If things were working fine this would display something like: Quote:URL: http://www.codeigniter.com Instead I get: Quote:Not Found Conclusion, it seems that CodeIgniter decodes the javascript urlencoded before it is told to do so. This results in requesting a URL that doesn't exist. Is there anybody who found a way to work around this? Thanks, Jochem PS. I tried to give full information I hope that I succeeded in it. In case you miss something please drop me a note. (I use a recent - last two weeks - download - last two weeks - of CodeIgniter). |
Messages In This Thread |
URL via javascript into CodeIgniter - by El Forum - 06-22-2007, 09:29 AM
URL via javascript into CodeIgniter - by El Forum - 06-22-2007, 05:49 PM
URL via javascript into CodeIgniter - by El Forum - 06-23-2007, 06:08 AM
URL via javascript into CodeIgniter - by El Forum - 06-23-2007, 12:26 PM
URL via javascript into CodeIgniter - by El Forum - 06-24-2007, 04:49 PM
|