submit button
-
Hi
I have a form that I created with php but the submit button does not work – the things is the URL looks right in the address bar and if I copy and paste it into a new tab it is fine
Code below
$html .= ‘<form method=”post” align=”center” action=”//rik.kirmada.com/process”>’;
$html .= ‘<input type=”hidden” id=”MSID” name=”MSID” value=”1″>’;
$html .= ‘Name:<br><input type=”text” name = “name” value=”‘ . $obj->MS_Name . ‘”><br>’;
$html .= ‘Notes:<br><textarea name=”notes” cols=”40″ rows=”5″>’ . $obj->MS_Notes . ‘</textarea><br>’;
$html .= ‘<input type=”submit” ></form>’;any help appreciated!!
The blog I need help with is: (visible only to logged in users)
-
Howdy –
Thanks for getting in touch.
For my own clarification I have a few questions.
– Are you working on rikkirmada.wordpress.com or a different site?
– Is the code intended to render a form on the front end of the site or do you want to just share the code as it is for viewing on the front end of the site? -
it is on rik.kirmada.com and it is intended to render a form. Basically I populate the form with data from the database (I didn’t show that bit but that works fine) and then I want to be able to edit the text (which again works fine) and submit the form. So I can create a form by just putting something like
<form method=”post” action=”//rik.kirmada.com/process”>
Name: <input type=”text” name=”fname” value=”” <input type=”submit”>
</form>Inside a block and that works fine but when I uses php to generate it like my first post it just says
The page you requested could not be found. Try refining your search, or use the navigation above to locate the post.
But the url in the address bar looks right and if I cut and paste it into a new tab it works????
-
Got it, so, rik.kirmada.com isn’t hosted here. I can’t see the back end or know for sure what page you’re using.
If you’re referring to the front page of the site, though, it seems you’ve got it set to show latest posts, but you’re only using pages.
I’d fix that and make it a static front page instead (which you can then add posts to if you want to).
Going forward, these forums are primarily for sites that use our free-tier hosting. We’re a little different from the WordPress software itself:
https://wordpress.com/go/website-building/wordpress-com-vs-wordpress-org/You’ll want to create an account at https://wordpress.org/support/forums/ so you’ll have access to the correct community for your site. There’s a developer forum here:
https://wordpress.org/support/forum/wp-advanced/Or, you’d be welcome to host here; your plan would get direct support, though advanced coding topics could still be outside our scope of support.
I hope this helps!
- The topic ‘submit button’ is closed to new replies.