Click here to Skip to main content
16,005,697 members
Home / Discussions / Web Development
   

Web Development

 
QuestionGetting Used to PHP Pin
Bram van Kampen26-Jun-10 13:02
Bram van Kampen26-Jun-10 13:02 
AnswerRe: Getting Used to PHP Pin
Peter_in_278027-Jun-10 15:41
professionalPeter_in_278027-Jun-10 15:41 
GeneralRe: Getting Used to PHP Pin
Bram van Kampen28-Jun-10 13:58
Bram van Kampen28-Jun-10 13:58 
QuestionSessions and cookiless property and URIs Pin
swjam23-Jun-10 4:21
swjam23-Jun-10 4:21 
AnswerRe: Sessions and cookiless property and URIs Pin
T M Gray25-Jun-10 9:45
T M Gray25-Jun-10 9:45 
Questionhow to analyst which website using webservice Pin
Naunt22-Jun-10 15:00
Naunt22-Jun-10 15:00 
AnswerRe: how to analyst which website using webservice Pin
Not Active22-Jun-10 15:25
mentorNot Active22-Jun-10 15:25 
QuestionDynamically add a LinkButton to a text stream? Pin
Gregory Gadow22-Jun-10 7:19
Gregory Gadow22-Jun-10 7:19 
This is way outside of any web development I've done so I am not quite sure even how to phrase the question.

I have some web code in master page that dynamically generates a list of user bookmark links, retrieved out of a SQL database. The first link on the generated list is one that allows the user to Add This Page or Remove This Page, depending on whether the page is already in the list of bookmarks. Here is the relevant code:
VB
If CanAddToFavorites Then
    If MyUser.Favorites.HasUrl(Url) Then
        Result.AppendFormat("<li><a href=""/Reps/Admin/ManageFavorites.aspx?op=r&amp;url={0}"">Remove This Page</a></li>", Url)
    Else
        Result.AppendFormat("<li><a href=""/Reps/Admin/ManageFavorites.aspx?op=a&amp;url={0}&amp;d={1}"">Add This Page</a></li>", _
        HttpUtility.HtmlEncode(Url), HttpUtility.HtmlEncode(PageFullTitle))
    End If
    Result.AppendLine()
End If

This works fine, but I am not happy with passing everything through the URL. Ideally, I would convert the a into a LinkButton; on postback the handler would wrap the data into a class, save it to Session and redirect to ManageFavorites.aspx.

I cannot hard-code the link, as bookmarking is available only to field users (back office users get a predetermined bookmark list that cannot be altered.) Given this constraint, how can I intercept a link click to perform server-side code? This sounds like a job for AJAX but I am totally ignorant about that tool so relevant examples would be a huge help.
AnswerRe: Dynamically add a LinkButton to a text stream? Pin
Not Active22-Jun-10 7:29
mentorNot Active22-Jun-10 7:29 
GeneralRe: Dynamically add a LinkButton to a text stream? Pin
Gregory Gadow22-Jun-10 7:53
Gregory Gadow22-Jun-10 7:53 
GeneralRe: Dynamically add a LinkButton to a text stream? Pin
Not Active22-Jun-10 8:03
mentorNot Active22-Jun-10 8:03 
GeneralRe: Dynamically add a LinkButton to a text stream? Pin
Gregory Gadow22-Jun-10 9:17
Gregory Gadow22-Jun-10 9:17 
GeneralRe: Dynamically add a LinkButton to a text stream? Pin
Not Active22-Jun-10 9:39
mentorNot Active22-Jun-10 9:39 
Questionlinking the domain name Pin
dahras19-Jun-10 21:42
dahras19-Jun-10 21:42 
AnswerRe: linking the domain name Pin
DaveAuld20-Jun-10 4:24
professionalDaveAuld20-Jun-10 4:24 
GeneralRe: linking the domain name Pin
dahras20-Jun-10 6:15
dahras20-Jun-10 6:15 
GeneralRe: linking the domain name Pin
DaveAuld20-Jun-10 6:22
professionalDaveAuld20-Jun-10 6:22 
GeneralRe: linking the domain name Pin
dahras20-Jun-10 7:02
dahras20-Jun-10 7:02 
GeneralRe: linking the domain name Pin
DaveAuld20-Jun-10 7:24
professionalDaveAuld20-Jun-10 7:24 
GeneralRe: linking the domain name Pin
dahras20-Jun-10 7:28
dahras20-Jun-10 7:28 
GeneralRe: linking the domain name Pin
DaveAuld20-Jun-10 7:39
professionalDaveAuld20-Jun-10 7:39 
GeneralRe: linking the domain name Pin
dahras21-Jun-10 12:23
dahras21-Jun-10 12:23 
GeneralRe: linking the domain name Pin
dahras20-Jun-10 7:45
dahras20-Jun-10 7:45 
GeneralRe: linking the domain name Pin
dahras20-Jun-10 6:42
dahras20-Jun-10 6:42 
GeneralRe: linking the domain name Pin
DaveAuld20-Jun-10 6:55
professionalDaveAuld20-Jun-10 6:55 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.