If this is your first visit, please click the Sign Up now button to begin the process of creating your account so you can begin posting on our forums! The Sign Up process will only take up about a minute of two of your time.

Results 1 to 2 of 2
  1. #1
    Junior Member
    Join Date
    Jul 2015
    Member #

    Post HELP WITH JavaScript

    Hi. I created a drop down text with JavaScript with the following script. The problem I am having is. That the code is listing the headers and the text linked to that. How can I put them side by side?

    Do I need to create a table with two rows, side by side and then add one header in the right and then one in the left, then make the table disappear?

    <script type="text/javascript">
    function toggleMe(a){
    var e=document.getElementById(a);
    var i = document.getElementById(a + '_image');
    if(!e)return true;
    i.src = 'images/ball1.png';
    } else {"none"
    i.src = 'images/ball.png';
    return false;

    <h3><a style="cursor: pointer;" onclick="return toggleMe('para1')"><style="border:0;margin-right:5px;vertical-align:middle;" />Random Text</a></h3>
    <div id="para1" style="display:none;">
    Random text
    <a href="domainname
    ">John Doe</a>
    <h3><a style="cursor: pointer;" onclick="return toggleMe('para2')"><style="border:0;margin-right:5px;vertical-align:middle;" />Header Text</a></h3>
    <div id="para2" style="display:none;">
    Drop down text. This will drop down when clicking on Header Text.
    <li><a href="domainname">Jane Doe</a></li>

    Hope you understand what I am trying to do. I'm new to all this, so would be greatful for a reply Thanks in advance


  3. #2
    Junior Member
    Join Date
    Dec 2015
    Athens, Greece
    Member #
    1 times
    If this post still exists, try to upload a link. To check it somewhere live, and to help you.

Remove Ads

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Tags for this Thread

All times are GMT -6. The time now is 02:16 PM.
Powered by vBulletin® Version 4.2.3
Copyright © 2022 vBulletin Solutions, Inc. All rights reserved.
vBulletin Skin By: