Linkposition in HTML Quellcode bestimmen (html, php, javascript)

  • Allgemein

Es gibt 2 Antworten in diesem Thema. Der letzte Beitrag () ist von DerPro.

    Linkposition in HTML Quellcode bestimmen (html, php, javascript)

    Hallo zusammen,

    ich habe ein etwas komplizierteres Problem.

    Ich habe eine Webseite gemacht, mithilfe eines CMS Systems von Worldsoft. Auf die Datenbank des Systems habe ich keine Zugrifssmöglichkeiten.

    Beim Aufru einer bestimmten Seite werden mir alle Briefkästen die in die Datenbank eingetragen wurden angezeigt. Man kann die Tabelle in der die Daten eingetragen werden selbst erstellen und so schreiben wie man es wünscht. Die Tabelle hat eine einzige ID, und diese Tabelle wird 100mal mit Daten gefüllt und dann angezeigt. Das heißt, es befinden dich 100 Tabellen auf einer seite, alle haben die Selbe ID (kann nicht geändert werden) und man muss eine bestimmte Tabelle weiter verarbeiten und zwar die Adressdaten und Leerunszeiten des Briefkastens.

    In den einzelnen Tabellen gibt es dann noch ein Link "weiter"....
    Wenn man auf den Link klickt soll die aktuelle position des Links erkannt werden und die Tabelle in der sich der Link befindet um dann die Daten zu lesen.

    Einmal ein Beispiel:

    Ich klicke auf den Link "weiter" in Tabelle 50, dann wird die Zeile im quellcode des Links ermittel. DIese wird in eine Funktion übergeben die dann die Daten aus der Tabelle liest in der ich auf den Link gedrückt habe, also Tabelle 51.

    Das gesamte System ist abgeschottet, man kann nur code in die Seiten einfügen, die ID's sind nicht veränderbar usw.....

    Hier mal Code der Seite:


    HTML-Quellcode

    1. <div id=portal_entry> <div id='portal_entry_overview'>
    2. <table id="tabelle" border="0" cellspacing="0" cellpadding="0" width="673">
    3. <tbody>
    4. <tr>
    5. <td class="th_big1" width="29" align="left"><strong>PLZ:</strong></td>
    6. <td class="th_big1" width="38" align="left">78224</td>
    7. <td class="th_big1" width="25" align="left"><strong>Ort:</strong></td>
    8. <td class="th_big1" width="163" align="left">Singen</td>
    9. <td class="th_big1" width="44" align="left"><strong>Stra&szlig;e:</strong></td>
    10. <td class="th_big1" width="180" align="left">Ekkehardstr. 37-39</td>
    11. <td class="th_big1" width="68" align="left"><strong>Leerungszeit:</strong></td>
    12. <td class="th_big1" width="40" style="text-align: center">16:15</td> </tr> </tbody> </table>
    13. <table border="0" cellspacing="0" cellpadding="0" width="673">
    14. <tbody>
    15. <tr> <td width="80"><strong>Standort:</strong></td>
    16. <td width="493">SÜDKURIER</td> <td width="100">&nbsp;</td> </tr>
    17. <tr> <td><strong>Bemerkung:</strong></td>
    18. <td></td> <td> <div style="text-align: right"><a href="/62"><font size="1">Zur&uuml;ck zur Suche</font></a></div> </td> </tr> </tbody> </table>
    19. <div id=portal_entry> <div id='portal_entry_overview'>
    20. <table id="tabelle" border="0" cellspacing="0" cellpadding="0" width="673">
    21. <tbody>
    22. <tr>
    23. <td class="th_big1" width="29" align="left"><strong>PLZ:</strong></td>
    24. <td class="th_big1" width="38" align="left">78224</td>
    25. <td class="th_big1" width="25" align="left"><strong>Ort:</strong></td>
    26. <td class="th_big1" width="163" align="left">Singen</td>
    27. <td class="th_big1" width="44" align="left"><strong>Stra&szlig;e:</strong></td>
    28. <td class="th_big1" width="180" align="left">Ekkehardstr. 37-39</td>
    29. <td class="th_big1" width="68" align="left"><strong>Leerungszeit:</strong></td>
    30. <td class="th_big1" width="40" style="text-align: center">16:15</td> </tr> </tbody> </table>
    31. <table border="0" cellspacing="0" cellpadding="0" width="673">
    32. <tbody>
    33. <tr> <td width="80"><strong>Standort:</strong></td>
    34. <td width="493">SÜDKURIER</td> <td width="100">&nbsp;</td> </tr>
    35. <tr> <td><strong>Bemerkung:</strong></td>
    36. <td></td> <td> <div style="text-align: right"><a href="/62"><font size="1">Zur&uuml;ck zur Suche</font></a></div> </td> </tr> </tbody> </table>
    37. <div id=portal_entry> <div id='portal_entry_overview'>
    38. <table id="tabelle" border="0" cellspacing="0" cellpadding="0" width="673">
    39. <tbody>
    40. <tr>
    41. <td class="th_big1" width="29" align="left"><strong>PLZ:</strong></td>
    42. <td class="th_big1" width="38" align="left">78224</td>
    43. <td class="th_big1" width="25" align="left"><strong>Ort:</strong></td>
    44. <td class="th_big1" width="163" align="left">Singen</td>
    45. <td class="th_big1" width="44" align="left"><strong>Stra&szlig;e:</strong></td>
    46. <td class="th_big1" width="180" align="left">Ekkehardstr. 37-39</td>
    47. <td class="th_big1" width="68" align="left"><strong>Leerungszeit:</strong></td>
    48. <td class="th_big1" width="40" style="text-align: center">16:15</td> </tr> </tbody> </table>
    49. <table border="0" cellspacing="0" cellpadding="0" width="673">
    50. <tbody>
    51. <tr> <td width="80"><strong>Standort:</strong></td>
    52. <td width="493">SÜDKURIER</td> <td width="100">&nbsp;</td> </tr>
    53. <tr> <td><strong>Bemerkung:</strong></td>
    54. <td></td> <td> <div style="text-align: right"><a href="/62"><font size="1">Zur&uuml;ck zur Suche</font></a></div> </td> </tr> </tbody> </table>
    Jein.....

    es ist ein CMS System. In diesem System gibt es Module die verschieden FUnktionen bereitstellen. Den Code für die Tabelle muss man eintragen, ohne werte.
    Dort wo die werte stehen Straße....Ort usw. werden im CMS Variablen eingetragen. Mehr kann man nicht machen...das wird alles automatisch generiert...alles php....


    oder gibt es eine Möglichkeit Javascript oder php code nur innerhalb eines bestimmten tags auszuführen?

    Dieser Beitrag wurde bereits 1 mal editiert, zuletzt von „DerPro“ ()