Jump to content

EDYYY

New Members
  • Posts

    8
  • Joined

  • Last visited

    Never

Posts posted by EDYYY

  1. actualy i've tried with onclick and the bugs still are there ...

     

    <td title='{$server['s']['name']}' style='text-align:left'>
    	   <p onclick=\"newDialog('detaills.php?s={$server['o']['id']}')\">{$misc['name_filtered']}}</p>
    
            </td>

    i hope this is what you asked..

    if you click slowly on one row, it openes the dialog, then click another row, it openes .. but if you click fast let's say one click / second on different rows, then the problem appears.

    with onmouseover is the same, the problem is that i don't know what function to call on onmouseout=close(event) or something like this ...

     

     

  2. i didn't understand a bit from there, but i managed to get the data. now, as a final push : how to make it to open in new box (onmouseover and onmouseout). I've seen something but i don't know how to connect what i have with what i should have ..

    here is my script:

     

    <script type="text/javascript" language="JavaScript">

    <!-- Copyright 2006 Bontrager Connection, LLC

    var cX = 0; var cY = 0;

    function UpdateCursorPosition(e){ cX = e.pageX; cY = e.pageY;}

    function UpdateCursorPositionDocAll(e){ cX = event.clientX; cY = event.clientY;}

    if(document.all) { document.onmousemove = UpdateCursorPositionDocAll; }

    else { document.onmousemove = UpdateCursorPosition; }

    function AssignPosition(d) {

    d.style.left = (cX+10) + "px";

    d.style.top = (cY+10) + "px";

    }

    function HideContent(d) {

    if(d.length < 1) { return; }

    document.getElementById(d).style.display = "none";

    }

    function ShowContent(d) {

    if(d.length < 1) { return; }

    var dd = document.getElementById(d);

    AssignPosition(dd);

    dd.style.display = "block";

    }

    function ReverseContentDisplay(d) {

    if(d.length < 1) { return; }

    var dd = document.getElementById(d);

    AssignPosition(dd);

    if(dd.style.display == "none") { dd.style.display = "block"; }

    else { dd.style.display = "none"; }

    }

    //-->

     

    $(function() {

     

    $(".info").hover(function()

    {

     

    var id = $(this).attr("id");

    var name = $(this).attr("name");

    var dataString = 'd='+ id ;

    var parent = $(this);

     

     

    if(name=='down')

    {

     

    $(this).fadeIn(200).html('<img src="loader.gif" align="absmiddle">');

    $.ajax({

      type: "POST",

      url: "player.php" + "?d=" + id ,

      data: dataString,

      cache: false,

     

      success: function(html)

      {

        parent.html(html);

     

      }  });

     

    }

    return false;

    });

     

    });

    </script>

     

    Also as you see here i already have a function that shows something on mouseover ..

     

    $playeri = "<a onmouseover=\"ShowContent('UNIQUEID'); return true;\" onmouseout=\"HideContent('UNIQUEID'); return true;\" href='".link($server['o']['id'])."' target=\"_self\">{$server['s']['playersmax']}</a>

    <div style=\"position:absolute;\" id=\"UNIQUEID\" class=\"FAQ\">Player</div> ";

     

    $harta = "<a href='' class='info' id={$server['o']['id']} name='down'>{$server['s']['map']}</a>";

     

    So how can i make it to show in a "pop-up", div, table or whatever it's called so you can understand me  :confused: I showed you the other function just to see that i already have one for mouseover function, maybe can be modified but it should not mess with the other content it displays..

     

    ps: Thanks a lot for youre help !

    Later edit: maybe if i can PM you the link, you can see better what i'm talking about ?

  3. thanks for your advice :)

    I googled it but with no results. I found some tutorials that works for one page(link) but now in my case here. I should say that i'm no coder, some stuff are are foreign language for me ..

    Can you please point me in the right direction ?

    By the way, excuse me for not "speaking" correctly.

     

  4. Hello. If someone can help me, i'll be grateful :shy:

    So i have a foreach and an $output .= function that fills some infos in a table. Inside it i have a div for each line that when hovering your mouse should get some data .. Here i have a big problem, because for each line it should get some data and i don't know how to do it ...

     

    i'll post here some of my code for better understanding.

     

    //some java here

    <?php

    require "class.php";

     

      $server_list = query_group();

      $misc  = server_misc($server);

     

    foreach ($server_list as $server)

        {

          $misc  = server_misc($server);

          $server = server_html($server);

          $idi = "{$server['o']['id']}";

    $harta = "<a onmouseover=\"ShowContent('harta'); return true;\" onmouseout=\"HideContent('harta'); return true;\" href='".link($server['o']['id'])."' target=\"_self\">{$server['s']['map']}</a>

    <div style=\"position:absolute;\" id=\"harta\" class=\"FAQ\">file_get_contents('http://mysite/player.php?d={$idi}')</div> ";

     

    $output .= "

    <table>

    ........... some code.....

    <td>

    {$harta}

            </td>

    .......

     

    so basicly when i hover my mouse over each row it should get data from the file for that id... The problem is that only one page can be loaded with file_get_contents. I read over the internet that some ajax functions can do it but i really don't know how.

    Please help me, i've been looking for 3 days already without any luck  :'(

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.