Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6230329
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T09:43:40+00:00 2026-05-24T09:43:40+00:00

I made a test website in MAMP. And all worked fine. However, when I

  • 0

I made a test website in MAMP. And all worked fine.

However, when I uploaded it I got alot of error messages on one crucial page.

The link to see the error messages are:

http://ryanmurphy.org.uk/musicsite/artist.php

I thought it may be useful to see the code for that page:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Ryan Murphy's Music Website</title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<img src="http://upload.wikimedia.org/wikipedia/commons/thumb/0/0a/BBC_Radio_1.svg/175px-BBC_Radio_1.svg.png">
<link rel="stylesheet" href="stylesheet.css" type="text/css" media="screen" />
<img src="http://blogs.howtogeek.com/mysticgeek/files/2008/08/618pxlast.fm-logo.svg.preview.png" style="padding-left:10px;">

</head>
<body>
<h1>Most popular artist this week</h1>
<div id="navbar"><ul>
<li><a href="index.php">Home</a></li>
<li><a href="music.php">Track Playlist from the last week</a></li>
<li><a href="artist.php">Most played Artist from the last week</a></li>
<li><a href="sources.html">Sources Used</a></li>

</ul>
</div>

<table>
<th>Artist</th>
<th>Times played this week</th>
<th>Previous plays</th>

<?php
foreach ($xml->artists->children() as $child)
{
  echo "<tr>";
  $artist = (string)$child->name;
  echo "<td>$artist</td>";
  $playedweek = (string)$child->plays;
  echo "<td>$playedweek</td>";
  $previousplays = (string)$child->previous_plays;
  echo "<td>$previousplays</td>"; 
  echo "</tr>";
}?>
</table>
</body>
</html>
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-24T09:43:41+00:00Added an answer on May 24, 2026 at 9:43 am

    You do a method call like this:

    $obj->children()
    

    However, $obj is not an object. Try var_dump($obj) to see what it contains.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I've made a website, to test the html5 audio. Unfortunately some browser doesn't support
why isn't the cookies storing? the local website I made has a setcookie(test,time()); in
A website I've made has a few problems... On one of the pages, wherever
I'm putting together a simple test made up of two tutorials available online for
I have a problem, and I made this test code to show you my
I have made a simple test application for the issue, two winforms each containing
I've made a simple test with a MemoryMappedFile as msdn says : 2 processes,
I have Ripple which im using to test app made for android. App is
I made quite a few easy OSGi test projects in Eclipse RCP. My typical
I made a 64-bit WPF test app. With my app running and with Task

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.