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

Using 2 results on one page, 'delete' not playing nicely

Thread began 9/16/2014 8:38 am by Jamie | Last modified 9/30/2014 12:00 pm by Jason Byrnes | 1180 views | 7 replies |

Jamie

Using 2 results on one page, 'delete' not playing nicely

Hey Jason

Have got to results on the attached page. If you hit delete on one of them, if the other has got an id of the same value then it also gets deleted. What have I done wrong to cause that to happen?

Cheers

Jamie

Sign in to reply to this post

Jason ByrnesWebAssist

Both forms have the same Delete button name. and both delete behaviors are triggered on Button: Delete pressed.

edit each of the delete buttons to use a unique name, and edit each of the delete behaviors to trigger on the corresponding uniquely named delete button.

Sign in to reply to this post

Jamie

have renamed them as:
<input type="submit" value="Delete" class="formButton" id="Delete" name="DeleteScroller" />
and
<input type="submit" value="Delete" class="formButton" id="Delete" name="DeleteSlideshow" />

i have also updated the triggers

if (isset($_POST["DeleteScroller"]) || isset($_POST["DeleteScroller_x"])) // Trigger

and

if (isset($_POST["DeleteSlideshow"]) || isset($_POST["DeleteSlideshow_x"])) // Trigger

do I need to change anything else - reason I ask is that both delete buttons now delete the scroller content so have clearly done something incorrectly

(file is attached)

Sign in to reply to this post

Jason ByrnesWebAssist

message me through skype tomorrow and I will look into this with you.

Sign in to reply to this post

Jamie

Hey Jason

Was trying to apply the changes we made to the above to another page that I was experienicng the same issue with (attached) and its nto working.

When I say its 'not working' regardless of which delete button is clicked nothing gets deleted.
Cheers
Jamie

Sign in to reply to this post

Jason ByrnesWebAssist

at line 114 and 145, you have both behaviors set to use the same delete button as the trigger:

if (isset($_POST["Delete"]) || isset($_POST["Delete_x"])) // Trigger


but, one of the delete buttons is named DeleteSlideshow and the other is named DeleteScroller


you will need to edit the code for the triggers to use the correct button names.

Sign in to reply to this post

Jamie

you da man!!! as ever many thanks mate

Jamie

Sign in to reply to this post

Jason ByrnesWebAssist

you're welcome.

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...