Jump to content

Apache and ajax


chapeen

Recommended Posts

I have a page where users can register. I use ajax.

http.open('get', 'RegisterUser.php?nombre='+nombre+'day='+dy+'month='+mnt+'year='+yr+'sex='+sex+'email='+email+' &password='+psw+'&nocache = '+nocache);

 

When I press on my submit button I get the message

"The requested URL /page/RegisterUser.php was not found on this server."

 

This is what I have in the .htaccess page

RewriteEngine On

RewriteRule ^page/([^/\.]+)/?$ index.php?page=$1

 

Can someone help, is there an extra rule to put on htaccess page ?

What am I doing wrong ?

Link to comment
https://forums.phpfreaks.com/topic/139053-apache-and-ajax/
Share on other sites

The page does exist and could it be that I should put my query as follows?

http.open('get','/page/RegisterUser/?nombre='+name+'&day='+dy+'&month='+mnt+'&year='+yr+'&sex='+sex+'&email='+email+'&password='+psw+'&nocache='+nocache)

 

When I do so , my index.php shows up as shown in the screenshot.

What would be right way to call my page using ajax and that also respects my htaccess rule ?

can somebody help ?

 

[attachment deleted by admin]

Link to comment
https://forums.phpfreaks.com/topic/139053-apache-and-ajax/#findComment-727803
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • 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.