Twokinds ARCHIVE Forums

This forum is for the preservation of old threads from before the forum pruning.
It is currently Tue Apr 15, 2025 4:51 pm

All times are UTC - 5 hours




Post new topic This topic is locked, you cannot edit posts or make further replies.  [ 34 posts ]  Go to page Previous  1, 2, 3  Next
Author Message
 Post subject:
PostPosted: Thu Jul 10, 2008 2:31 am 
Offline
Council Member
User avatar

Joined: Fri Dec 08, 2006 2:06 am
Posts: 544
Location: Behind my computer.
Here you go:
http://robbiethe1st.ktserv.com/foreveryone/file.rar

A demo of it:
http://robbiethe1st.ktserv.com/foreveryone/file.php

I have added some instructions for use, but I am not good at making tutorials. I hope everything is fine. If you have some suggestions, just ask.


-RobbieThe1st


Top
 Profile  
 
 Post subject:
PostPosted: Thu Jul 10, 2008 3:21 am 
Offline
Apprentice
User avatar

Joined: Sun May 11, 2008 3:08 pm
Posts: 124
Location: limbo...
thanks everyone :3
i really appreciate the help
sorry for no updates today, i was out getting some cabling to switch the server to my dual p3, and turn my less than stable desktop back into a desktop and a case for the computer i am building my little sister[she turned 11 on the 8th, bit late but i promised her a computer :3]
as soon as i move i will get upgraded internets, so it wont be "OMG its so slow" kind of slow...
i will try to get updates tomorrow, and a few more pages. cant garrentee anything, i have to move it all over to my dual p3 while setting up an OS on my sisters computer to be[which after hours of building into the punny case, has a blown power supply unique to that case -. -]

night for now


Top
 Profile  
 
 Post subject:
PostPosted: Sun Jul 13, 2008 2:38 am 
Offline
Apprentice
User avatar

Joined: Sun May 11, 2008 3:08 pm
Posts: 124
Location: limbo...
so after todays mishap resulting in the death of a crappy ps2 controller, i am returning to fiddling with the server
first off, im going to try to create a news section, the question is how
i have the idea in my head, of a javascript function that will search a directory in the webservers root for a .txt/html file with the highest number, and embed it within a frame
i figure then i can make a txt/html file for news, give it a sequential number[first named 1.txt, second entry 2.txt, so on] and then the javascript will take the most recent one[with the highest number] and display that, and i can have a link to the past ones below
im pretty sure it can be done, or something close to it, i jsut need some help to do it
and before it is said, i allways try to google things before asking, so i have googled this and am still reading the pages[or will in the morning]
if anyone can help with this, it would be appreaciated


Top
 Profile  
 
 Post subject:
PostPosted: Sun Jul 13, 2008 9:26 pm 
Offline
Templar Inner Circle
User avatar

Joined: Wed Jan 17, 2007 12:33 pm
Posts: 2879
Location: Nebraska, USA
Considering that you're trying to search your sever for a specific file (albeit not terribly specific), you might be better off using PHP for this rather than Javascript. Usually PHP runs your server side layer and Javascript is your client side layer. So displaying the news is given to PHP to do (or at the very least, finding the news to display), while Javascript is given the task of asking PHP to change which news item to display if the user hits a hypothetical next or previous button. I mean, you probably could do it in raw Javascript, but it's certainly not the easy way.

This is a lazy, and probably inefficent, way to do what you want to do.
Code:
<?php
// get all of the possible news articles.  This is the lazy, inefficient bit.
$arrayOfNewsArticles = glob( 'news/*.html' );
// That array is ordered in ascending order.  So we obviously want the
//  one on the very end, as it's most recent.
$mostRecentNews = $arrayOfNewsArticles[count($arrayOfNewsArticles)-1];
// Now let's just display the most recent news.  We'll do it inside a div, just
//  in case you do want to use AJAX to change it.  Loading as the source of
//  an IFRAME would also be a pretty easy way to handle it.
echo( "<div id='news'>\n" );
echo( file_get_contents( 'news/'.$mostRecentNews ) );
echo( "\n</div>\n" );
?>


The list of links is really quite easy to do from here, especially if you choose to do an IFRAME, since you can simply use the name/id of the IFRAME as the "target" for the link.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Jul 14, 2008 1:12 am 
Offline
Apprentice
User avatar

Joined: Sun May 11, 2008 3:08 pm
Posts: 124
Location: limbo...
another language to learn on vacation tomorrow...
im going up north to visit some relatives for a while and am thinking i should find some place to download a few pdf docs or txt docs to read on the 2 day bus ride
i prefere text/html cause i can use my sansa e200, as my laptop battery lasts about 30minutes, or 45 if i kill the backlight
so my new question, is anyone got resources to link me to that i can download[basically ebooks on this html, javascript and php] and how can i update the site[enable remote controlling] from locations otehr than at the computer itself[im using the latest version of apache if that helps]
i have the rest of tonight and a little of tomorrow morning[the rest will be spent packing and digging for device cables], then im going to van to catch a bus northward around 3 >. >


Top
 Profile  
 
 Post subject:
PostPosted: Mon Jul 14, 2008 10:47 am 
Offline
Templar Inner Circle
User avatar

Joined: Wed Jan 17, 2007 12:33 pm
Posts: 2879
Location: Nebraska, USA
You probably won't see this before you leave, but here's my two cents:

I'm a bad use case. I tend to consult the Tubes for Javascript questions, harnessing Google (since the boss won't buy us a new O'Reilly book). For PHP, I pretty much exclusively consult their website for reference: http://www.php.net Considering I mention it; the O'Reilly Javascript reference is phenomenal. I believe that it is available in one fashion or another online, though I have to admit a preference for the dead tree version.

PHP is designed to run inline with HTML: you're editing the same files, and they might even have literally the same content. Or they might include some PHP sections, which the server will parse and do work on. It's still just a plaintext file, it still can be edited by notepad. The only real difference is that you use ".php" for the extension instead of ".html" or ".htm," so that Apache knows to run the PHP parser over the file before sending it through the Tubes to your user.

What do you mean "update the site [via] remote controlling?" There are a couple different options out of that. You could do something like VNC or RDC, which covers the "remote controlling" aspect (RDC should be built into your copy of Windows, VNC is available for every major platform and is free). If you're just looking to "update the site" by uploading new versions of the files, that's usually handled via FTP or SFTP.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Jul 14, 2008 12:01 pm 
Offline
Apprentice
User avatar

Joined: Sun May 11, 2008 3:08 pm
Posts: 124
Location: limbo...
i just woke up and so i may not sound completely sane[i definately dont look it >. >] but i have jsut read your message, and i did figure out how to setup php[and indeed, it works but the code you gave me doesnt seem to. i downloaded the php manual in html format for my sansa from the php site, and am getting some help in ##php on freenode, so i should be set there[yay another new language to learn xP], so now its a matter of setting up vnc on both the laptop and server and getting that to work before i leave >. <


Top
 Profile  
 
 Post subject:
PostPosted: Mon Jul 14, 2008 12:42 pm 
Offline
Templar Inner Circle
User avatar

Joined: Wed Jan 17, 2007 12:33 pm
Posts: 2879
Location: Nebraska, USA
BlueFoxx wrote:
i just woke up and so i may not sound completely sane[i definately dont look it >. >] but i have jsut read your message, and i did figure out how to setup php[and indeed, it works but the code you gave me doesnt seem to.

It would require some customizing to make it work properly. Your server has suddenly decided it doesn't like me, so I can't offer much advice right now.

VNC should be a snap to have up and working, since you've got a public IP. I don't think you'll have any problems with it.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Jul 14, 2008 2:23 pm 
Offline
Apprentice
User avatar

Joined: Sun May 11, 2008 3:08 pm
Posts: 124
Location: limbo...
the server was down cause i was moving my router so i could easily unplug it so i could take it north with me and leach internets off of whoever i stay with, it should be working now. as for VNC, i got that going now and am on my desktop from the laptop...
the trip has been postponed until tomorrow at 8AM[i hate mornings lol] so i have the rest of today to pack and whatnot...which also means i have another night to work on the website
i got that news.php script going now, so im just working on a template for a news/blog type thing.
on another related subject, would anyone happen to have a copy of my disclaimer i made? the file i had in the server was accidentally overwritten and i had to delete it :\
so if anyone has any way to get it back...i would be extremely greatful


Top
 Profile  
 
 Post subject:
PostPosted: Wed Jul 16, 2008 2:18 am 
Offline
Apprentice
User avatar

Joined: Sun May 11, 2008 3:08 pm
Posts: 124
Location: limbo...
and incase you didnt read the update on the first post:the site is official>http://bluefoxx.selfip.net
much happieness ensues for me, as im going up north tomorrow to visit relatives, and get pictures for the pics section to be made]


Top
 Profile  
 
 Post subject:
PostPosted: Wed Jul 16, 2008 2:30 am 
Offline
Templar Inner Circle
User avatar

Joined: Wed Jan 17, 2007 12:33 pm
Posts: 2879
Location: Nebraska, USA
'Gratz on the domain name.

Oh, I haven't ever used gedit, but there's always gVim. ;)


Top
 Profile  
 
 Post subject:
PostPosted: Wed Jul 16, 2008 2:47 am 
Offline
Apprentice
User avatar

Joined: Sun May 11, 2008 3:08 pm
Posts: 124
Location: limbo...
avwolf wrote:
'Gratz on the domain name.

Oh, I haven't ever used gedit, but there's always gVim. ;)

thanks ^^
whats gvim about BTW? cross platform?


Top
 Profile  
 
 Post subject:
PostPosted: Wed Jul 16, 2008 3:10 am 
Offline
Templar Inner Circle
User avatar

Joined: Wed Jan 17, 2007 12:33 pm
Posts: 2879
Location: Nebraska, USA
gVim is Vim, but with the necessary extensions to run in a graphical environment, like X or Windows. It's cross platform, and otherwise just a text editor, albeit a very powerful one with regular expressions for search and replace, formatting options, and syntax highlighting. I did all my programming in school using Vim, so I prefer it on my Linux boxen. When I'm editing files on my Windows box, I tend to use the Windows gVim port as well. It's a great editor, but, as a forewarning, Vim's got a learning curve, and can seem pretty arcane at first.


Top
 Profile  
 
 Post subject:
PostPosted: Wed Jul 16, 2008 3:30 am 
Offline
Apprentice
User avatar

Joined: Sun May 11, 2008 3:08 pm
Posts: 124
Location: limbo...
avwolf wrote:
gVim is Vim, but with the necessary extensions to run in a graphical environment, like X or Windows. It's cross platform, and otherwise just a text editor, albeit a very powerful one with regular expressions for search and replace, formatting options, and syntax highlighting. I did all my programming in school using Vim, so I prefer it on my Linux boxen. When I'm editing files on my Windows box, I tend to use the Windows gVim port as well. It's a great editor, but, as a forewarning, Vim's got a learning curve, and can seem pretty arcane at first.

allright, thanks

will try it out


Top
 Profile  
 
 Post subject:
PostPosted: Wed Aug 27, 2008 10:47 am 
Offline
Merchant
User avatar

Joined: Sun Apr 06, 2008 1:34 am
Posts: 155
Location: In a Potato inside of a Cheescake thats in a Barrel
interesting... ill bookmark it and look at it when i feel like it, i been having probs hosting for games and stuff so yeah....


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic This topic is locked, you cannot edit posts or make further replies.  [ 34 posts ]  Go to page Previous  1, 2, 3  Next

All times are UTC - 5 hours


Who is online

Users browsing this forum: No registered users and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group