Go Back   CodingForums.com > Web Projects and Services Marketplace > Web Projects > Small projects (quick fixes and changes)

Notices

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 07-18-2012, 01:54 PM   PM User | #1
embeebutterly
New Coder

 
Join Date: Jan 2011
Posts: 64
Thanks: 7
Thanked 0 Times in 0 Posts
embeebutterly is an unknown quantity at this point
$30 for a solution Qjury - .json retrieve info

Payment $30 by paypal
Hi guys, i could do with some help with this if you can please.

In a nutshell im building an epg, i have found some json files that i can use to give me all the info i need but getting the correct data is proving difficult

the code i have is working to a point it will get the first 2 eliments (Channel name, Channel ID) but not the rest of the info. What i would like to achieve is this:

Code:
<table width="270" border="0">
          <tr>
            <td width="144">channel_name</td>
            <td width="116"><h4><a href="sequence_id" target="more_info_iframe">sequence_name</a></h4></td>
            </tr>
          <tr>
            <td>channel_name</td>
            <td><h4><a href="sequence_id" target="more_info_iframe">sequence_name</a></h4></td>
          </tr>
        </table>
The Point being it will print all the info and make the show its self clickable so its unique id will bring up the further info like discription, start time etc.

My code looks like this:
Code:
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js"></script>
    <script type="text/javascript"> 

    $(document).ready(function() {
            $('#submit').click(function () {
        $.ajax({

   
    type:"GET",
    url:"test.json",
    dataType:"json",
   

    success: function (data) {      
    var epgresult="<ul>";
    $.each(data, function(i,n){
    epgresult+="<li>"+n["channel_name"]+","+n["channel_id"]+","+n["channel_sequence_schedule_id"]+"</li>";
            });
    epgresult+="</ul>";
    $('#message').append(epgresult);
    document.writeln(epgresult);
}
});
return false;
});
});


    </script>
    </head>
<body>
    
        <input type="button" onClick="getjson()" value="pressme"         style="align:center" />    
        <div id="messege"> <input type="button" id="submit" value="Load EPG" ></div><script type="text/javascript">
		
		</script>

And the Json file looks like this:
Code:
[{"channel_id":"1","channel_name":"BBC 1","schedule":
[{"channel_sequence_schedule_id":"2594872","sequence_id":"2594891","sequence_name":"World Business Report","description":"The latest business news, with informed analysis.","starts_at":1342067400,"ends_at":1342068300,"duration":900,"pre":0,"post":0},

{"channel_sequence_schedule_id":"2645926","sequence_id":"2645945","sequence_name":"BBC News","description":"","starts_at":1342068300,"ends_at":1342069200,"duration":900,"pre":0,"post":0},{"channel_sequence_schedule_id":"2645927","sequence_id":"2645946","sequence_name":"Breakfast","description":"Round-up of national and international news, plus the latest from the money markets.","starts_at":1342069200,"ends_at":1342080900,"duration":11700,"pre":0,"post":8100}]},

{"channel_id":"2","channel_name":"BBC 2","schedule":
[{"channel_sequence_schedule_id":"2595313","sequence_id":"2595332","sequence_name":"Schools: Music, Mud and Making Money","description":"Radio 1 DJ Greg James explores businesses involved in music festivals to explain five concepts - entrepreneurship, sole trading, franchises, companies and profit and loss. Designed for GCSE business studies students.","starts_at":1342067400,"ends_at":1342069200,"duration":1800,"pre":0,"post":0},

{"channel_sequence_schedule_id":"2646373","sequence_id":"2646392","sequence_name":"The Pingu Show","description":"Two vintage episodes and the chance to learn more about the world of penguins.","starts_at":1342069200,"ends_at":1342069800,"duration":600,"pre":0,"post":0},

{"channel_sequence_schedule_id":"2646374","sequence_id":"2646393","sequence_name":"Zigby","description":"Zara's sandcastle vanishes, leaving Zigby to find an explanation for its disappearance.","starts_at":1342069800,"ends_at":1342070700,"duration":900,"pre":0,"post":0},

{"channel_sequence_schedule_id":"2646375","sequence_id":"2646394","sequence_name":"Timmy Time","description":"The friends pretend to run businesses, but Timmy and Finlay do not have enough money to buy a toy and set up rival shops - until they realise it is better working together.","starts_at":1342070700,"ends_at":1342071300,"duration":600,"pre":0,"post":0},

{"channel_sequence_schedule_id":"2646376","sequence_id":"2646395","sequence_name":"Dirtgirlworld","description":"The Creepy Crawly Concert takes place in dirtgirlworld.","starts_at":1342071300,"ends_at":1342072200,"duration":900,"pre":0,"post":0},

{"channel_sequence_schedule_id":"2646377","sequence_id":"2646396","sequence_name":"Rastamouse","description":"Roadworks and diversions prevent a famous musician joining the Easy Crew for a performance, and Gladstone Brie worries the music festival will be ruined.","starts_at":1342072200,"ends_at":1342072800,"duration":600,"pre":0,"post":0}]},
I really hope someone can help me with this problem, i can set up a test page if it helps anyone.

NB: the main thing im after is getting the specific info after [{"channel_sequence_schedule_id"


I need to be able to seperate each show, and it must give me full controll over each show, time, title etc. But most importantly ACCESS THE DATA AFTER [{"channel_sequence_schedule_id"


Thank you in advance

Payment $30 by paypal
embeebutterly is offline   Reply With Quote
Old 07-19-2012, 06:19 AM   PM User | #2
chuffman
New Coder

 
Join Date: Jul 2009
Location: Evansville, Indiana
Posts: 20
Thanks: 0
Thanked 0 Times in 0 Posts
chuffman is an unknown quantity at this point
I've solved your problem, contact me via PM with some type of IM handle and I can show you it!

Thanks!
chuffman is offline   Reply With Quote
Old 07-23-2012, 03:03 PM   PM User | #3
hdewantara
Regular Coder

 
hdewantara's Avatar
 
Join Date: Aug 2009
Location: Jakarta, Indonesia.
Posts: 287
Thanks: 4
Thanked 39 Times in 39 Posts
hdewantara is an unknown quantity at this point
Hi embeebutterly,
I would like help... if this is still open?

Hendra
hdewantara is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 08:54 PM.


Advertisement
Log in to turn off these ads.