Jump to content

pseud

Members
  • Posts

    21
  • Joined

  • Last visited

    Never

Everything posted by pseud

  1. The results on my script are from the previous day whereas the ones on the actual XML file are more recent, I said in my first post
  2. Oh right, I was gonna say - my site is SMF and only has a few custom pages. I apologise for my bad information by the way. I'm new to this scene, ill not say stuff unless I'm totally sure now. I don't wanna be that forum guy who pretends to know everything haha x
  3. Exactly what are you getting (we cannot help with anything unless you show us what exactly it is) and have you confirmed if the rss data at the specific time the problem occurred is correct or not? I'm going to guess that your input data is incorrect, possibly because of the php time zone setting vs the time zone where you and your browser are at. Aha, that would make sense actually, do you know how I can work around that? Thanks
  4. You looked at my website? What's wrong with it?
  5. Yeah this is what I saw, shouldn't you be using <?php ?
  6. It's not like any browsers deny invalid markup, if it works then it works, surely? I guess it's an opinion, I gave a working solution but it depends on the user whether or not they're happy to use invalid markup in their document - it's unfair to call my solution invalid based on your opinion of it though.
  7. Oh okay, thanks, DOMDocument isn't working properly then. Cheers, I'll do it your way (EDIT) Wait, something's wrong here - not sure what. I'm still getting old results, even with your method. What could be causing this? It's the same in both Chrome and Firefox
  8. pseud

    Floating Div

    In the CSS, put .myDiv { float: left; } Change left with whatever side you want it to float (right or left) then call it in the html like so <div class="myDiv"></div> There you have a floating div.
  9. What you can do, is put a submit button inside an anchor tag, so assuming you're using a button, you can make it open in a new tab like this: <a href="http://link.link" target="_blank"><input type="submit" /></a> In terms of having it inside a select, you'll have to do something like this: case "wgoogle": if($_GET["pressed"]==1) echo '<script type="text/javascript">window.open("http://gumclan.org", "_blank");</script>'; break; But for me, that's opening in a new window and not a new tab. I hope I helped in some way
  10. Okay - I'll do that. This is the RSS feed: <?xml version="1.0" encoding="ISO-8859-1"?> <rss version="0.92" xml:lang="en-US"> <channel> <title>Grand United Military</title> <link>http://gumclan.org/index.php</link> <description><![CDATA[Live information from Grand United Military]]></description> <item> <title>Re: Low Land Lions vs Fnatic.MSI</title> <link>http://gumclan.org/index.php?topic=1452.msg14412#msg14412</link> <description><![CDATA[<div class="quoteheader"><div class="topslice_quote"><a href="http://gumclan.org/index.php?topic=1452.msg14411#msg14411">Quote from: Furial on <strong>Today</strong> at 11:08:08 AM</a></div></div><blockquote class="bbc_standard_quote"><div class="quoteheader"><div class="topslice_quote"><a href="http://gumclan.org/index.php?topic=1452.msg14410#msg14410">Quote from: BeastR on <strong>Today</strong> at 11:05:15 AM</a></div></div><blockquote class="bbc_alternate_quote"><div class="quoteheader"><div class="topslice_quote"><a href="http://gumclan.org/index.php?topic=1452.msg14406#msg14406">Quote from: fryz0 on <strong>Today</strong> at 10:20:26 AM</a></div></div><blockquote class="bbc_standard_quote">[quote author=BeastR link=topic=1452....</blockquote><div class="quotefooter"><div class="botslice_quote"></div></div></blockquote><div class="quotefooter"><div class="botslice_quote"></div></div></blockquote><div class="quotefooter"><div class="botslice_quote"></div></div>]]></description> <author>lurtz833@hotmail.com</author> <category><![CDATA[Multimedia]]></category> <comments>http://gumclan.org/index.php?action=post;topic=1452.0</comments> <pubDate>Mon, 06 Aug 2012 10:27:09 GMT</pubDate> <guid>http://gumclan.org/index.php?topic=1452.msg14412#msg14412</guid> </item> <item> <title>Re: Low Land Lions vs Fnatic.MSI</title> <link>http://gumclan.org/index.php?topic=1452.msg14411#msg14411</link> <description><![CDATA[<div class="quoteheader"><div class="topslice_quote"><a href="http://gumclan.org/index.php?topic=1452.msg14410#msg14410">Quote from: BeastR on <strong>Today</strong> at 11:05:15 AM</a></div></div><blockquote class="bbc_standard_quote"><div class="quoteheader"><div class="topslice_quote"><a href="http://gumclan.org/index.php?topic=1452.msg14406#msg14406">Quote from: fryz0 on <strong>Today</strong> at 10:20:26 AM</a></div></div><blockquote class="bbc_alternate_quote"><div class="quoteheader"><div class="topslice_quote"><a href="http://gumclan.org/index.php?topic=1452.msg14400#msg14400">Quote from: BeastR on <strong>Today</strong> at 06:04:42 AM</a></div></div><blockquote class="bbc_standard_quote">noob teams specially lighters all bi...</blockquote><div class="quotefooter"><div class="botslice_quote"></div></div></blockquote><div class="quotefooter"><div class="botslice_quote"></div></div></blockquote><div class="quotefooter"><div class="botslice_quote"></div></div>]]></description> <author>furial2_robin@live.nl</author> <category><![CDATA[Multimedia]]></category> <comments>http://gumclan.org/index.php?action=post;topic=1452.0</comments> <pubDate>Mon, 06 Aug 2012 10:08:08 GMT</pubDate> <guid>http://gumclan.org/index.php?topic=1452.msg14411#msg14411</guid> </item> <item> <title>Re: Low Land Lions vs Fnatic.MSI</title> <link>http://gumclan.org/index.php?topic=1452.msg14410#msg14410</link> <description> <![CDATA[<div class="quoteheader"><div class="topslice_quote"><a href="http://gumclan.org/index.php?topic=1452.msg14406#msg14406">Quote from: fryz0 on <strong>Today</strong> at 10:20:26 AM</a></div></div><blockquote class="bbc_standard_quote"><div class="quoteheader"><div class="topslice_quote"><a href="http://gumclan.org/index.php?topic=1452.msg14400#msg14400">Quote from: BeastR on <strong>Today</strong> at 06:04:42 AM</a></div></div><blockquote class="bbc_alternate_quote">noob teams specially lighters all big noobs bait each other 0 skill cheters<br /></blockquote><div class="quotefooter"><div class="botslice_quote"></div></div><br />fnatic.MSI may bey noob...</blockquote><div class="quotefooter"><div class="botslice_quote"></div></div>]]> </description> <author>lurtz833@hotmail.com</author> <category><![CDATA[Multimedia]]></category> <comments>http://gumclan.org/index.php?action=post;topic=1452.0</comments> <pubDate>Mon, 06 Aug 2012 10:05:15 GMT</pubDate> <guid>http://gumclan.org/index.php?topic=1452.msg14410#msg14410</guid> </item> <item> <title>Re: What song are you listening to right now?</title> <link>http://gumclan.org/index.php?topic=591.msg14408#msg14408</link> <description><![CDATA[<embed src="http://www.youtube.com/v/vPVlGWhk0LA&rel=1&fs=1" type="application/x-shockwave-flash" allowFullScreen="true" allowScriptAccess="never" wmode="transparent" width="425px" height="350px"><noembed><a href="http://www.youtube.com/watch?v=vPVlGWhk0LA" target="_blank">http://www.youtube.com/watch?v=vPVlGWhk0LA</a></noembed></embed>]]></description> <author>furial2_robin@live.nl</author> <category><![CDATA[Music]]></category> <comments>http://gumclan.org/index.php?action=post;topic=591.0</comments> <pubDate>Mon, 06 Aug 2012 10:03:14 GMT</pubDate> <guid>http://gumclan.org/index.php?topic=591.msg14408#msg14408</guid> </item> <item> <title>Re: Low Land Lions vs Fnatic.MSI</title> <link>http://gumclan.org/index.php?topic=1452.msg14407#msg14407</link> <description> <![CDATA[<div class="quoteheader"><div class="topslice_quote"><a href="http://gumclan.org/index.php?topic=1452.msg14406#msg14406">Quote from: fryz0 on <strong>Today</strong> at 10:20:26 AM</a></div></div><blockquote class="bbc_standard_quote"><div class="quoteheader"><div class="topslice_quote"><a href="http://gumclan.org/index.php?topic=1452.msg14400#msg14400">Quote from: BeastR on <strong>Today</strong> at 06:04:42 AM</a></div></div><blockquote class="bbc_alternate_quote">noob teams specially lighters all big noobs bait each other 0 skill cheters<br /></blockquote><div class="quotefooter"><div class="botslice_quote"></div></div><br />fnatic.MSI may bey noob...</blockquote><div class="quotefooter"><div class="botslice_quote"></div></div>]]> </description> <author>furial2_robin@live.nl</author> <category><![CDATA[Multimedia]]></category> <comments>http://gumclan.org/index.php?action=post;topic=1452.0</comments> <pubDate>Mon, 06 Aug 2012 10:00:16 GMT</pubDate> <guid>http://gumclan.org/index.php?topic=1452.msg14407#msg14407</guid> </item> </channel> </rss> This is what the page shows Recent Topics Title: Re: Promod map overview. Category: General Promod Talk Link: Re: Promod map overview. Publish date: Mon, 06 Aug 2012 06:59:47 GMT Title: Re: Promod map overview. Category: General Promod Talk Link: Re: Promod map overview. Publish date: Sun, 05 Aug 2012 19:38:02 GMT Title: Re: Promod map overview. Category: General Promod Talk Link: Re: Promod map overview. Publish date: Sun, 05 Aug 2012 15:02:23 GMT Title: Re: Promod map overview. Category: General Promod Talk Link: Re: Promod map overview. Publish date: Sun, 05 Aug 2012 12:53:53 GMT Title: Re: Promod map overview. Category: General Promod Talk Link: Re: Promod map overview. Publish date: Sun, 05 Aug 2012 12:52:45 GMT And this is the script <h3>Recent Topics</h3> <?php //Set new DOMDocument and load the RSS feed with it. $doc = new DOMDocument(); $doc->load('http://gumclan.org?action=.xml;type=rss'); //Set count variable to limit amount of items shown with RSS //$i = 0; //For each <item> in the RSS feed: foreach($doc->getElementsByTagName('item') as $docItem) { //Fill up an array with all of the written tags $docArray = array( 'title' => $docItem->getElementsByTagName('title')->item(0)->nodeValue, 'link' => $docItem->getElementsByTagName('link')->item(0)->nodeValue, 'category' => $docItem->getElementsByTagName('category')->item(0)->nodeValue, 'pubDate' => $docItem->getElementsByTagName('pubDate')->item(0)->nodeValue ); //Display the information in chosen format echo('Title: ' . $docArray['title'] . '<br /> Category: ' . $docArray['category'] . '<br /> Link: <a href="' . $docArray['link'] . '">' . $docArray['title'] . '</a><br /> Publish date: ' . $docArray['pubDate'] . '<br /><br />'); /* //Increment $i $i++; //If $i passes >2, stop the loop. This will stop it at 3 items if ($i > 2) {break;}*/ }
  11. Please can someone help me here? I need this to work!
  12. The 1st reply states that he has his die(); in the wrong place, which isn't the problem at all I'm not trying to rage at anyone, or anything like that, I'm just asking why everyone is talking about the die(); function when that's not the problem xD
  13. The problem I'm seeing is that he is using mysql_result() with the variable containing the query, not a variable containing mysql_query(the query); - So the parameter for the function is wrong. Can anyone else not see this? It's typical for this error message, why has nobody else said this yet?
  14. Please can you show me the MYSQL Query you're using to get the information?
  15. Sorry, but no replies so I'm bumping. Hope there's no rule against it
  16. Semicolons are irregular as separators. The ampersand is by far the most used method. Ahh okay, sorry for my misleading information. I've learned something here too Thanks, pseud
  17. If I'm correct, you need to use an actual mysql_query function as the 1st parameter. So try this: $query = "SELECT `balance` FROM `cobblecr_minecraft` WHERE 'username = $search' LIMIT 0, 30 " or die(mysql_error()); $runQuery = mysql_query($query); mysql_result( $runQuery, 0, 'username');
  18. Yes, you'd use the semicolon for this, so the URL would read this for example: http://url.com?id=5;name=chris;function=example etc. Is this what you meant?
  19. I wrote a small PHP script to parse an RSS feed, but it's giving results that are 1 day old, even though the latest one on the RSS feed is around 5 hours old. Could you say what I'm doing wrong please? Here is the RSS feed: http://gumclan.org?action=.xml;type=rss Here is the page of mine that has the script behind it: http://gumclan.org/pseud/ And here is the code: http://pastebin.com/iLfKAqrW Thanks!
×
×
  • 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.