close ad
Install the LAtest Updates to Work with CC 2017 and CC 2018
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

visitors update no record found after login

Thread began 3/02/2010 2:43 pm by donald.dickson338135 | Last modified 3/03/2010 4:38 pm by donald.dickson338135 | 707 views | 4 replies |

donald.dickson338135

visitors update no record found after login

Hello - another request for help I'm afraid!
So, after three days of making various mistakes, receiving help and figuring lots of things out for myself I am stuck again!
I am still working everything through using local host and I managed to get all the pages doing what I expected.
My latest learning exercise was to redirect the visitor (or Admin or Power User) to the visitor_Profile.php page. I followed the steps in the video and set the SecurityAssist Authenticate User Server behaviour to "if login succeeds to go to visitor_Profile.php"

The database has all the visitors registered plus one other that I have entered to test the function of adding a visitor.

Now the problem. When a visitor logs in (any including Admin, Power User, Visitor or the one I added) what I get in the browser window is "No record found".
So this is reasonably clear, even to me, that the behaviour cannot find a visitor record. What I cannot work out is why?
The user is logged in at the appropriate security level, so clearly that bit of the behaviour works.

I took a look at the code on visitor_Profile.php that includes
</form>
<?php } // Show if recordset not empty ?>
<?php if ($totalRows_WAATKvisitors == 0) { // Show if recordset empty ?>
<div>No record found.</div>
<?php } // Show if recordset empty ?>
</div>

But, when I use the Search function I can see that I have 12 rows of visitor information so why am I getting the "No record found" message?

Could the following be the reason?
When I first set up the provided database I set up a connection "blue_sky_music" to set up the database for the web site. Then once the web site was created from the provided files, along came another connection connBSM so I have two database connections blue-sky_music and connBSM both of which connect to the visitors table.

Following the tutorials I discovered I had to use connBSM to make things work -and it does as I have suggested, I can add, delete and search for records in the visitors table.
So - given that I have set the SecurityAssist Authenticate User Server behaviour for visitor_Profile.php to connBSM I wonder could it be that connBSM cannot find the visitors table from this particular page?
I am reluctant to change something without checking because I have had more than one episode of things going horribly wrong resulting in me starting from scratch again.

Can you point me in the right direction please?
Thanks
Don

Sign in to reply to this post

Jason ByrnesWebAssist

Please send a copy of the login and the profile page so I can examine the code.

Sign in to reply to this post

donald.dickson338135

Log In and Profile Pages as requested

Hello Jason and thank you for responding to my question.
As requested I have attached two text files with copies of the code from each page.
Awaiting the outcome of your review to see what I have done wrong on this occasion.

Incidentally, I can confirm that if I purposely type an incorrect password for a user the form behaviour correctly redirects to the forgot email page as set up. So that bit works.
Best wishes
Don

Attached Files
v-login-code.txt
v_profile-code.txt
Sign in to reply to this post

Jason ByrnesWebAssist

the login page is only storing the userLevel in a session variable. It needs to store the VisitorID as well.



double click the Security Assist Authenticate User server behavior, On the third step, click the plus button and select the VisitorID column to have the VisitorID stored in a session variable, then click OK.

Sign in to reply to this post

donald.dickson338135

That's a result!

Hello Jason and thank you for responding to my "challenge"
Your solution worked - everyone a winner! as they say.
Clearly my concerns over the database connection were unfounded, much to my relief.
I am still not sure how I missed inserting the original Visitor_ID Session variable - To help me learn I will look at the revised updated code and see what has changed.
Thanks again for taking the time to help me out.
Much appreciated.
Don

Sign in to reply to this post

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...