close ad
WARNING PC USERS: Do Not Install the DREAMWEAVER CC 2017 Update »
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

Adding additional conditions to existing if/else statements

Thread began 6/13/2013 6:28 am by info441120 | Last modified 6/14/2013 8:54 am by info441120 | 238 views | 2 replies

info441120

Adding additional conditions to existing if/else statements

Hi All

Below is some code that I am using in a catalog page where customers can click on products and either pay with paypal or Call to Order. This is handled by and if/esle statement which is currently working fine. However I need to add conditional statements so that if a certain condition isn't meet then the "Options" dropdown menu wont appear when paying with paypal.

I hope this is clear and someone can help point me in the right direction. Not quite sure where in the code I would need to add and for that matter what I would need to add.

Any help would be greatly appreciated, thanks


<div class="WADAResultCommerceButton">
<?php if($row_WADAtb_accessories['call_to'] == "") { ?>
<div class="WADAResultCommerceButton">
<form target="paypal" action="https://www.paypal.com/cgi-bin/webscr" method="post">
<input type="hidden" name="cmd" value="_cart" />
<input type="hidden" name="add" value="1" />
<input type="hidden" name="bn" value="webassist.dreamweaver.4_5_0" />
<input type="hidden" name="business" value="info@ramosmusic.com.au" />
<input type="hidden" name="item_name" value="<?php echo $row_WADAtb_accessories['prod_name']; ?>" />
<input type="hidden" name="item_number" value="<?php echo $row_WADAtb_accessories['prod_ID']; ?>" />
<input type="hidden" name="amount" value="<?php echo $row_WADAtb_accessories['price_r']; ?>" />
<input type="hidden" name="currency_code" value="AUD" />
<input type="hidden" name="receiver_email" value="info@ramosmusic.com.au" />
<input type="hidden" name="mrb" value="R-3WH47588B4505740X" />
<input type="hidden" name="pal" value="ANNSXSLJLYR2A" />
<input type="hidden" name="no_shipping" value="0" />
<input type="hidden" name="no_note" value="0" />
<br />
Reed Sizes:
<input type="hidden" name="on0" value="Reed Sizes" />
<select name="os0">
<option value="1.5">1.5</option>
<option value=" 2"> 2</option>
<option value=" 2.5"> 2.5</option>
<option value=" 3"> 3</option>
</select>
Qty:
<input type="text" name="quantity" value="1" style="width:40px" />
<br />
<br />
<input type="image" name="submit" src="https://www.paypal.com/en_US/i/btn/x-click-but10.gif" border="0" alt="Make payments with PayPal - it's fast, free and secure!" />
</form>
</p>
</div>
</div>
</div>
<div class="WADARecordNavigationButtons"></div>
</div>
<?php } else {?>
<?php echo '<br />
<br /><a href="contacts.html"><img src="images/call.png" width="120" height="26" /></a>' ?>
<?php } ?></td>

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