This topic is locked

Individual image on Menu Page

12/26/2005 6:48:09 AM
ASPRunnerPro General questions
R
Robert author

Is there a way where I could have an image (a company logo, for instance) on the menu page which would appear acording to the user?

Something like having a datafile image field in the users table...which code could be used? Don´t know if this is the best and easiest approach...
Also, is there a date for the release of the 4,0 Beta version?

Thanks,

Robert

Sergey Kornilov admin 12/27/2005

Robert,
after succeffull login you can save image name to session variable:

Session("ImageName") = rs("ImageName")


On the top of menu page you can use the following:

<%
Response.Write "<img src=""images/" & Session("ImageName") & """>"
%>


Please note this is just a sample code and needs to be adjusted according to your task.

R
Robert author 12/27/2005

What happens is I make the site available for different customers to see their own data.

What I would like is to display each ones company logo on the menu page...

This means that according to the user logged in, a corresponding image would be shown - based on a field on the users table.
Imagine my user table has the following fields: ID, UserName, Client, Password, Image, FileName, where Image is an OLE field (and database Image File within ASPRunner).

Which would be my steps?

Thanks in advance,

Robert

Sergey Kornilov admin 12/28/2005

I just explained what you need to do in my previous post.
Just a minor note - my schema assumes you store in the database just image file name not the actual image. If you prefer to store actual image file in the database you need to build a call to imager.asp to display database-based image. Persoanlly I would recommend to store images somewhere on the Webserver.