Go Back   CodingForums.com > :: Client side development > HTML & CSS

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 03-14-2013, 05:14 AM   PM User | #1
wella58
New to the CF scene

 
Join Date: Mar 2013
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
wella58 is an unknown quantity at this point
Call another file in downloading

I need help on this code:

Code:
<div id="dl-container">
<ul id="dl-icons">
<li id="word-icon"><strong>Download:<br></strong><a class="fancybox" style="color: #ffffff;" href="#contact_form_pop"><img src="http://www.templatebowl.com/wp-content/uploads/2013/03/word-icon-a.png" height="38" width="38"></a>
<div class="fancybox-hidden" style="display: none;">
<div id="contact_form_pop">[email-download download_id="27" contact_form_id="697"]</div></div>


</li>
<li id="psd-icon"><a class="fancybox" style="color: #ffffff;" href="#contact_form_pop"><img src="http://www.templatebowl.com/wp-content/uploads/2013/03/psd-icon-a.png" height="38" width="38"></a>
<div class="fancybox-hidden" style="display: none;">
<div id="contact_form_pop">[email-download download_id="40" contact_form_id="697"]</div></div>

</li>
</ul>
</div>
Our download button works by entering a name and email address then, it will send the file to the email address inputted by the user. The problem is, we have two buttons on the page, one is for Word format and the other is for PSD. But everytime I download a PSD file, it calls the Word file. I don't know what's wrong. I double checked the download id of the file and there seems to be nothing wrong with the IDs. Please help me. I need to finish it today. Here's the page: http://www.templatebowl.com/5-x-7-postcard-template/ . Try and see what's wrong.
wella58 is offline   Reply With Quote
Old 03-14-2013, 06:01 PM   PM User | #2
sunfighter
Senior Coder

 
Join Date: Jan 2011
Location: Missouri
Posts: 2,365
Thanks: 18
Thanked 348 Times in 347 Posts
sunfighter is on a distinguished road
Both of your anchors go to the same place href="#contact_form_pop" This maybe your problem you do not differentiate between them.
sunfighter is offline   Reply With Quote
Old 03-15-2013, 12:34 AM   PM User | #3
wella58
New to the CF scene

 
Join Date: Mar 2013
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
wella58 is an unknown quantity at this point
But it's suppose to go to the same anchor.
wella58 is offline   Reply With Quote
Old 03-15-2013, 03:13 PM   PM User | #4
sunfighter
Senior Coder

 
Join Date: Jan 2011
Location: Missouri
Posts: 2,365
Thanks: 18
Thanked 348 Times in 347 Posts
sunfighter is on a distinguished road
Just wondering how contact_form_pop knows what button was pushed? And that where I would look next.
sunfighter is offline   Reply With Quote
Old 03-15-2013, 07:31 PM   PM User | #5
jerry62704
Senior Coder

 
jerry62704's Avatar
 
Join Date: Oct 2007
Location: Springfield, IL
Posts: 1,042
Thanks: 9
Thanked 81 Times in 81 Posts
jerry62704 is on a distinguished road
Quote:
Originally Posted by wella58 View Post
But it's suppose to go to the same anchor.
If it goes to the one and only anchor then how will it know which one invoked it?

You can't have two IDs with the same name. You are confusing the system with the results you are seeing.
__________________
.
.
...and gladly would he learn and gladly teach

Visit www.LiberalsWin.com for humor and the unique Bush/Obama Approval Polls
jerry62704 is offline   Reply With Quote
Old 03-15-2013, 09:39 PM   PM User | #6
Chrystyan
New Coder

 
Join Date: Mar 2013
Location: Indiana
Posts: 26
Thanks: 0
Thanked 7 Times in 7 Posts
Chrystyan is an unknown quantity at this point
You don't have to change the IDs for the popup, you nearly need to handle what is being received by the popup better with Javascript. You can change the innerHTML to do that. You may want to do a bit of research on that if it's something you're considering.
Chrystyan is offline   Reply With Quote
Old 03-16-2013, 12:30 AM   PM User | #7
wella58
New to the CF scene

 
Join Date: Mar 2013
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
wella58 is an unknown quantity at this point
Thanks so much for all your feedback. I finally got it. I assigned different values on the id.
wella58 is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 12:32 AM.


Advertisement
Log in to turn off these ads.