Current location: Hot Scripts Forums » General Web Coding » JavaScript » [SOLVED] Google Checkout logo demands its own line. How to prevent?


Google Checkout logo demands its own line. How to prevent?

Closed Thread
  #1 (permalink)  
Old 03-26-10, 07:01 PM
Leafgreen's Avatar
Leafgreen Leafgreen is offline
Newbie Coder
 
Join Date: Feb 2008
Location: C:\Wonderland
Posts: 54
Thanks: 5
Thanked 0 Times in 0 Posts
Question Google Checkout logo demands its own line. How to prevent?

Hi all and TIA for your help.

I want to add this Google Checkout provided script to add to a table row of other logos.
Code:
<div id="googleCheckoutLogo"></div><script src='https://checkout.google.com/buttons/logos?merchant_id=4181961xxxxxxxx&loc=en_US&f=png' ></script>
But when I put it in between the other logos, it causes a line break above and below. Is there a way to make it stay on the same row?

BTW, when I remove <div id="googleCheckoutLogo"></div> then the logo does not appear.
  #2 (permalink)  
Old 03-26-10, 07:22 PM
wirehopper's Avatar
wirehopper wirehopper is offline
-
 
Join Date: Feb 2006
Posts: 2,515
Thanks: 20
Thanked 109 Times in 106 Posts
HTML Code:
<head>
<style type="text/css">
.row div
{
float:left;
}
</style>
</head>
<body>
<div class="row">
<div id="googleCheckoutLogo"></div>
<div id="anotherlogo"><img src="logo.gif" /></div>
</div>
Not tested
The Following User Says Thank You to wirehopper For This Useful Post:
Leafgreen (03-29-10)
  #3 (permalink)  
Old 03-26-10, 07:27 PM
Leafgreen's Avatar
Leafgreen Leafgreen is offline
Newbie Coder
 
Join Date: Feb 2008
Location: C:\Wonderland
Posts: 54
Thanks: 5
Thanked 0 Times in 0 Posts
ok so where do I put <script src='https://checkout.google.com/buttons/logos?merchant_id=4181961xxxxxxxx&loc=en_US&f=png' ></script> in your code?
  #4 (permalink)  
Old 03-26-10, 07:37 PM
wirehopper's Avatar
wirehopper wirehopper is offline
-
 
Join Date: Feb 2006
Posts: 2,515
Thanks: 20
Thanked 109 Times in 106 Posts
Right after the div - as you had it. I didn't copy it because it was long. The float left should solve the alignment issue.
The Following User Says Thank You to wirehopper For This Useful Post:
Leafgreen (03-29-10)
  #5 (permalink)  
Old 03-26-10, 07:55 PM
Leafgreen's Avatar
Leafgreen Leafgreen is offline
Newbie Coder
 
Join Date: Feb 2008
Location: C:\Wonderland
Posts: 54
Thanks: 5
Thanked 0 Times in 0 Posts
Wirehopper Thank you I tried to make it work, but it didn't work because I've got all this other crap. I'm just going to give it all to you and hopefully you can make it work.
HTML Code:
 <td align="center" valign="middle"><table align="center" border="0">
                        <tr valign="middle">
                                                  
                            </td>
<style type="text/css">
.row div
{
float:left;
}
</style>
<div class="row">
<div id="anotherlogo"><!-- Begin Official PayPal Seal -->
                            <a href="https://www.paypal.com/us/verified/pal=xxxxxxxxxx" target="_blank"><img src="http://www.paypal.com/en_US/i/icon/verification_seal.gif" border="0" alt="xxxxxxx"></A>
                            <!-- End Official PayPal Seal --></div>
<div id="anotherlogo"><script language="Javascript" src="https://seal.godaddy.com/getSeal?sealID=xxxxxxxxxxxxxxxxxx"></script></div>
<div id="googleCheckoutLogo"></div><script src='https://checkout.google.com/buttons/logos?merchant_id=4181961xxxxxxxxxx&loc=en_US&f=png' ></script>
      </div>

 <div id="anotherlogo">  <img src="/xxxxxxxxxxx" alt="The xxxxxx." title="xxxxxx." width="" height=""> </div>
<div id="anotherlogo"><a href="xxxxxxxxx" ><img src="/xxxxxxxxxx" border="0" alt="xxxxxx." title="xxxxxxxxx." width="" height=""></a></div>
						 </tr>
                      </table>

Last edited by wirehopper; 03-26-10 at 09:01 PM. Reason: HTML tags
  #6 (permalink)  
Old 03-26-10, 09:01 PM
wirehopper's Avatar
wirehopper wirehopper is offline
-
 
Join Date: Feb 2006
Posts: 2,515
Thanks: 20
Thanked 109 Times in 106 Posts
ids have to be unique. When I wrote "id='anotherlogo'" I was just giving a placeholder.

You don't have to give them ids, I put one on there in case you had more divs like that.

The Google one is probably all set, now, just add new divs as you need to, and assign them ids as necessary, or not at all.

The .row div in the style tags means that for all divs contained in a container of class row should be floated left, meaning without breaks between them.

A great resources is W3Schools Online Web Tutorials.

Keep going, your code is coming along nicely.
The Following User Says Thank You to wirehopper For This Useful Post:
Leafgreen (03-29-10)
  #7 (permalink)  
Old 03-26-10, 09:14 PM
Leafgreen's Avatar
Leafgreen Leafgreen is offline
Newbie Coder
 
Join Date: Feb 2008
Location: C:\Wonderland
Posts: 54
Thanks: 5
Thanked 0 Times in 0 Posts
I tried all these:
* change <div id="anotherlogo"> to <div>
* change <div id="anotherlogo"> to <div id="">
* change <div id="anotherlogo"> to <div id="1">, <div id="2">, and so on.
Still same result. Please see the attached pic.
Attached Images
File Type: jpg 3-26-2010 10-12-18 PM.jpg (18.1 KB, 390 views)
  #8 (permalink)  
Old 03-27-10, 06:20 PM
wirehopper's Avatar
wirehopper wirehopper is offline
-
 
Join Date: Feb 2006
Posts: 2,515
Thanks: 20
Thanked 109 Times in 106 Posts
Please post your code, it's probably something small.
The Following User Says Thank You to wirehopper For This Useful Post:
Leafgreen (03-29-10)
  #9 (permalink)  
Old 03-29-10, 02:12 AM
Leafgreen's Avatar
Leafgreen Leafgreen is offline
Newbie Coder
 
Join Date: Feb 2008
Location: C:\Wonderland
Posts: 54
Thanks: 5
Thanked 0 Times in 0 Posts
Trophee

Wirehopper solved my problem by creating a css style:
.row div
{
height:100px;
float:left;
}
.googleCheckoutLogo,.godaddy
{
padding:25px 0;
}

Then, before the set of logos, we put <div class="row">
Then before and after each logo, I just add a <div></div>

Done! Thank you Wirehopper!!!!!!!!!!
!!!!!!!
!!!!!!!!
  #10 (permalink)  
Old 03-31-10, 05:27 PM
Leafgreen's Avatar
Leafgreen Leafgreen is offline
Newbie Coder
 
Join Date: Feb 2008
Location: C:\Wonderland
Posts: 54
Thanks: 5
Thanked 0 Times in 0 Posts
Hey Wirehopper, were you able to figure out the middle vertical alignment? That part is not working...
Closed Thread

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

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 Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Moving division chiragkhunti CSS 5 03-19-09 12:47 PM
No error message... stormshadow PHP 3 12-11-06 06:31 PM
Redirection back to a page from form submit DAL Perl 11 03-21-05 02:45 PM
I most definately suggest DevelopingCentral.com For Any Website Design/Development! Salty777 General Advertisements 2 10-01-04 04:27 AM
asp-iis-Server error nsuresh_rasr ASP.NET 3 02-08-04 12:47 AM


All times are GMT -5. The time now is 02:02 AM.
vBulletin® Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.