kalster Posted December 14, 2014 Share Posted December 14, 2014 I have short urls on the same page that this javascript code is on. the problem is that the code now can't find the poll.php. I have tried the full path and full url to the poll.php, but the code still outputs file not found. how to get this code working? $.post('poll.php', $(this).serialize(), function(data, status){ Link to comment https://forums.phpfreaks.com/topic/293095-javascript-cant-find-file-404/ Share on other sites More sharing options...
requinix Posted December 15, 2014 Share Posted December 15, 2014 Taking a guess, The URL has to be absolute. That means a leading slash and the full path to where poll.php is. $.post('/path/to/poll.php', $(this).serialize(), function(data, status){ Link to comment https://forums.phpfreaks.com/topic/293095-javascript-cant-find-file-404/#findComment-1499582 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.