Here we have tabbed form http://www.ansonika.com/citytours/admin.html
At the settings part we can change password and email and we are using CodeIgniter server side validation. If we got any error page will reload but first tab will be open.
How we can display that error at the settings tab (Third tab) we are working on?
We though about moving to the first tab that section but when the page is open we need to show booking list.
Related
I'm building a WordPress site with a modal window for entering search terms. On submit, the modal window is supposed to close and the search results are returned on the search results page.
I've tried WordPress' native search functionality (4.7), as well as Search Filter Pro (2.2). Both search forms work correctly and reroute if they are used in the main content area, NOT in a modal.
example.com/search/?_sf_s=pigs (I cannot show the dev site without client permission)
But when using the modal window, upon submit, the page does not redirect, but the URL query changes to:
example.com/?_sf_search%5B0%5D=pigs&_sf_submit=Search
I'm using Bootstrap 3 for the modal, but I've also tried another jQuery plugin (leanModal.js). Both of them reproduce the problem in the exact same way.
Is there a fundamental problem with submitting a form in a modal window? Is the closing of the modal window triggering a callback that somehow prevents the form _POST from firing? Has anyone encountered this problem before?
Any feedback would be appreciated.
Thx,
Michael
My main application opens an user page. There are New / Edit / Delete buttons on the same page.
I am using Datatables Editor to display records. When I click on New button an lightbox opens up and the datatables editor build-in plugin shows add user template. When this template is submitted a new record is created. The backend has a AUTO_INCREMENT key which I want to be passed back to main page such that I display a message 'User ID : XXXXX has been created'
The issue is that even though I pass it as a session variable the main page which I believe since it is already loaded and cannot be refreshed after lightbox page is submitted - it never receives the updated session variable. As such session variable though set dynamically when user submits lightbox from backend is never seen in main page
How can I achieve the desired output?
I have a signup page designed with PHP and HTML for back end connectivity.
After the button click is made entering the details, I display the message Success on the same page with the help of JavaScript.
I need the details to get stored after the button click (its working fine), what I want is after the button is clicked and the PHP database page is opened. I don't want that page to be opened after the button click.
The same signup page should be retained with the entered information saved in the database.
Is there any way to do this?
So right now, on submit, it goes to a page that stores all the data and displays a "database page". But you don't want it to do that, you just want it to go back to the index page, or to a page that says success. Correct?
If that's the case, you can use this on your "database page".
header('Location:http://yoursite.com/path/to/login.php');
I have a page with tabs using twitter bootstrap and for tabs I'm using this modification https://github.com/twitter/bootstrap/pull/581#issuecomment-4828029 that gives me url's like index.php?id=1#/profile ( in case profile tab is active ), index.php?id=1#/contact ( in case contact tab is active ).
The problem is when I'm submitting a form the page that handles the form sends me back with $_SERVER['HTTP_REFERER'] but its not redirecting me to index.php?id=1#/profile it redirects me to index.php. As I understand it's because the the #/profile is client side and the index.php is server-side. Is there any way making the page that handles the form redirect back and make the last visited tab active ?
Add a hidden field to the form and put the hash in it. Then have your form processing script append the hash to the referer when constructing the redirect.
Another option is to put the current tab in a cookie, and select that tab whenever the page is opened.
I'm doing a system where the pages are displayed by tabs (easytabs Plugin http://os.alfajango.com/easytabs/#tabs1-js)
At one point in the process it performs a query in the database, where we
see all the details of each item that appears. I'd like to go into the details of the item, click back to the (on broswer or a button) the page to return to the list displayed by the SQL query, just as with any single page, but currently it only displays a blank page.
I wonder how can I do to implement this solution using the layout tabs.
Thank you.
There are various ways to maintain UI state. One of them is using a "url hash". For example, you click tab 2, change the url hash to:
mypage.php#tab=2
Then if someone presses BACK and goes FORWARD, you use JavaScript to look at the URL has and determine that the user had previously pressed tab 2, so you run your own bit of code that triggers the same event.
I'm unfamiliar with "easytabs" so I'm sorry I can't help with the specific implementation details, but that's the gist of the technique.