Jump to content
  • 0

Problema citire cod php in ipb


Question

Posted

Salutare. In seara asta am vrut sa introduc un script php prin blocks de la sectiunea page management. Am facut totul la carte, am inserat manual scriptul, am selectat ca totul sa fie citit php dar pana la urma el nu il citeste corect si arata asa: https://prnt.sc/idsnmb

tin sa mentionez ca nu functioneaza nici efectul de hover, nici nu apar toate cele ce trebuie

codul este urmatorul: 

$groupname = "p0wergame";
$xml = simplexml_load_file("http://steamcommunity.com/groups/".$groupname."/memberslistxml/?xml=1");
foreach ($xml->groupDetails->groupName as $name) {}
foreach ($xml->groupDetails->avatarFull as $icon)
 echo "<div class='dpx-steamSidebar'>";
		{ echo "<div class='dpx-steamSidebar-avatar' style='background-image: url($icon);'>
          <div class='dpx-steamSidebar-avt-radials'>
            <svg class='dpx-sa-rad2'>
  				<circle cx='50' cy='50' r='40'></circle>
			</svg>
            <svg class='dpx-sa-rad1'>
  				<circle cx='50' cy='50' r='40'></circle>
			</svg>
          </div>
        </div>"; }
		  echo "<div class='uk-grid'>";
		  echo "<div class='dpx-steamSidebar-name'> $name </div>";
foreach ($xml->groupDetails->memberCount as $member)
		{ echo " <div class='dpx-steamSidebar-stat'> Members <div class='dpx-steamSidebar-stat-num'> $member </div> </div>"; }
foreach ($xml->groupDetails->membersInGame as $ingame)
		{ echo "<div class='dpx-steamSidebar-stat'> In Game <div class='dpx-steamSidebar-stat-num'> $ingame </div> </div>"; }
foreach ($xml->groupDetails->membersOnline as $online)
		{ echo "<div class='dpx-steamSidebar-stat'> Online <div class='dpx-steamSidebar-stat-num'> $online </div> </div>"; }
		  echo "<a href='http://steamcommunity.com/groups/".$groupname."/' class='dpx-steamSidebar-button'>VIEW AND JOIN</a>";
		  echo "</div>";
		   echo "</div>";

daca vreti live, aveti forumul: LINK

Putin ajutor va rog, dau funda:) 

9 answers to this question

Recommended Posts

  • 0
Posted (edited)

Nu este scriptul dopePX doar de design ii fct de dopepx il postasi eu pe undeva faza era ca trebuie sa cauti extensia de la php

de ex:

<php>

<?php

Edited by Sn!k3rs
  • 0
Posted
5 minutes ago, Sn!k3rs said:

Nu este scriptul dopePX doar de design ii fct de dopepx il postasi eu pe undeva faza era ca trebuie sa cauti extensia de la php

de ex:

<php>

<?php

Esti culmea, eu am șters acele doua linii fiindcă ipb ul nu mi le a mai cerut. 

  • 0
  • Moderators
Posted

La al doilea foreach ai un statement si apoi o pereche de acolade care n'au niciun sens pentru ca fiecare iteratie la foreach o sa iti execute doar echo'ul ala. sigur nu trebuia acolada aia { imediat dupa foreach?

  • 0
Posted
16 hours ago, Daniel H. said:

 


$groupname = "p0wergame";
$xml = simplexml_load_file("http://steamcommunity.com/groups/".$groupname."/memberslistxml/?xml=1");
foreach ($xml->groupDetails->groupName as $name) {}
foreach ($xml->groupDetails->avatarFull as $icon)
 echo "<div class='dpx-steamSidebar'>";
		{ echo "<div class='dpx-steamSidebar-avatar' style='background-image: url($icon);'>
          <div class='dpx-steamSidebar-avt-radials'>
            <svg class='dpx-sa-rad2'>
  				<circle cx='50' cy='50' r='40'></circle>
			</svg>
            <svg class='dpx-sa-rad1'>
  				<circle cx='50' cy='50' r='40'></circle>
			</svg>
          </div>
        </div>"; }
		  echo "<div class='uk-grid'>";
		  echo "<div class='dpx-steamSidebar-name'> $name </div>";
foreach ($xml->groupDetails->memberCount as $member)
		{ echo " <div class='dpx-steamSidebar-stat'> Members <div class='dpx-steamSidebar-stat-num'> $member </div> </div>"; }
foreach ($xml->groupDetails->membersInGame as $ingame)
		{ echo "<div class='dpx-steamSidebar-stat'> In Game <div class='dpx-steamSidebar-stat-num'> $ingame </div> </div>"; }
foreach ($xml->groupDetails->membersOnline as $online)
		{ echo "<div class='dpx-steamSidebar-stat'> Online <div class='dpx-steamSidebar-stat-num'> $online </div> </div>"; }
		  echo "<a href='http://steamcommunity.com/groups/".$groupname."/' class='dpx-steamSidebar-button'>VIEW AND JOIN</a>";
		  echo "</div>";
		   echo "</div>";

 

Mutasem acolada aia dar nu mai funcționează deloc, dacă ai putea sa modifici și sa mi lași aici.

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • 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.