Jump to content

kirill578

Members
  • Posts

    29
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

kirill578's Achievements

Member

Member (2/5)

0

Reputation

  1. I have a website in which al the content is displayed in the same page with AJAX. As I know the browser doesn't send any data to the server after the hash symbol ( # ). But the only way to change address bar with no refreshing is location.hash. My question is how can I make the user be able to share the URL that will say ajax what page to load. - I don't want to make text field with the URL - you can look at the website here maadif.co.cc/stuff
  2. try this: RewriteEngine on RewriteBase / RewriteRule ^([a-zA-Z0-9]+) users.php?username=$1 RewriteRule ^([a-zA-Z0-9]+)/([a-zA-Z0-9]+)$ $2.php?username=$1
  3. It wasn't the problem.. some other ideas?
  4. How do I send multiple headers with this code? <?php $postdata = http_build_query( array( 'var1' => 'some content', 'var2' => 'doh' ) ); $opts = array('http' => array( 'method' => 'POST', 'header' => 'Content-type: application/x-www-form-urlencoded', 'content' => $postdata ) ); $context = stream_context_create($opts); $result = file_get_contents('http://example.com/submit.php', false, $context); ?> *this header: User-Agent: Mozilla/5.0 (iPhone; U; CPU iPhone OS 3_0 like Mac OS X; en-us) AppleWebKit/528.18 (KHTML, like Gecko) Version/4.0 Mobile/7A341 Safari/528.16
  5. How do I redirect this: http://maadif.co.cc/stuff/#!/18 to here http://maadif.co.cc/stuff/?id=18 * 18 is a variable I have tried \/ but it doesn't work (it doesn't set the value) Options +FollowSymlinks RewriteEngine on RewriteRule ^sutff/#!/([0-9]+) http://maadif.co.cc/stuff/?id=$1 [R,NC]
  6. I have found a solution I redirect http://maadif.co.cc/stuff/#!/ to http://maadif.co.cc/stuff/
  7. Ok, so how do i put variable from the address bar info variable, for instance: http://maadif.co.cc/stuff/#!/5 into id = 5; ???
  8. Is it possible that to change the address to something else with out reloading the page? I understand that if it were possible it could make a real security issue (Phishing and so on). but I need it just to change the value of some GET variable , in case some of the user want to share this page on facebook or send the perticiler page to someone. ( all the website is just one page and it's using AJAX ) There is the website in case you didn't got the point: http://maadif.co.cc/stuff/ !-! currently I use \/ but it does refresh the page. window.location.href = "http://maadif.co.cc/stuff/?id=" +question_id;
  9. Thanks, the problem was 3 blank lines at after the ?> tag
  10. I have some page that generates JSON array but the problem that java script ajax can't recognize it as a JSON code because it begins in the third line of the output ( press CTRL+U to see it ) I found out that the problem is my function php page that is Included ( include() ) there. but this function page doesn't send any output?! what is the problem!? http://maadif.co.cc/stuff/ajax_request.php
  11. I have finally found out that the problem is the PHP file its output starts in the third line..
  12. That is exactly what I did. Just look at the code here http://maadif.co.cc/ajax/prefer/index.php
  13. I downloaded FireBug. Is says that the POST send successful and it gets the right response but the problem has I already said before is that it doesn't execute the success function. I tried to add alert into it but i doesn't apper as well. ( My feeling that jQuery hates me :'( )
  14. Now i have the same problem, it doesn't execute anything Can you look at the code here? http://maadif.co.cc/ajax/prefer/index.php
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.