Geekzone: technology news, blogs, forums
Guest
Welcome Guest.
You haven't logged in yet. If you don't have an account you can register now.


50 posts

Geek


Topic # 14174 19-Jun-2007 20:43

Okk well saying you didint have a place for website help i though i will post here. Okk well i have to make a CSS website for my clan i have dreamweaver for the coding and photoshop to make my template and all but i cant seem to work out how to links things i can link them to straight  .php but i dont want that. I want it somthing like this http://*****.com/?op=home or somthing like that not just http://*****.com/index.php... Anyone can help me on this please?

Create new topic
123 posts

Master Geek


  Reply # 75305 20-Jun-2007 11:39
Send private message

You could use apache rewrite commands. If you have access to the apache config file, you can put them in there. If you don't have access, you can put rewrites in the .htaccess file in the directory your scripts are in.

http://httpd.apache.org/docs/1.3/misc/rewriteguide.html

Hope that helps.

Rob

122 posts

Master Geek


  Reply # 75339 20-Jun-2007 15:56
Send private message

I want it somthing like this http://*****.com/?op=home or somthing like that not just http://*****.com/index.php...

Sounds like you just need to make index.php execute as the default page for a directory. Then you could just type http://*****.com and be served http://*****.com/index.php automatically.

For Apache, modify "httpd.conf". Find this line: 'DirectoryIndex index.html' and change it to 'DirectoryIndex index.php index.html'. In IIS6, open Control Panel > Administrative tools > IIS manager. Right click on the desired website & select properties. Go to the documents tab & select 'Enable default content page'. Add 'index.php' to the list. Note, this is slightly different for IIS6 in Vista but the same principle applies.




50 posts

Geek


  Reply # 75369 20-Jun-2007 17:54

Ok well i will try the rewrite code thingy. Right now i have set the website up with AppServ and going to get a web host tomorrow or something. The httpd.conf file was already done... I was looking up online about it you can do some PHP coding to do it but i dont know it >__< if any one else has some iders please post them

EDIT: just looked at the rewrite thingy but man it is hard i am soooooo confused

1677 posts

Uber Geek
+1 received by user: 7

Trusted

  Reply # 75422 20-Jun-2007 21:49
Send private message

as a side, i have found App Serv is a really easy way to install a PHP/MySQL web server on a PC. Saves buggering about a lot with the setup files etc, especially if you're a bit of a newbie in this regard.





http://www.phpeasystep.com/downloadsview.php?id=5"

:edit: can't figure out the BBCode to embed a URL into the message

208 posts

Master Geek


Reply # 75665 22-Jun-2007 15:19
Send private message

As stated, if you wish to get creative .htaccess is probably your best bet.
In .htaccess you can force a PHP file(s) to be seen as part of your URI and thus use it as a switch for all your other URL/URI.
This way all your URI look well formed. i.e no queries.
A quick Google (without plugging someone elses site :-)  to save me typing:

       www dot sitearticles dot com/index.php/?m=show&opt=printable&id=18
He, he, look at that URL, that's a giggle. PHP/Apache geek humour I guess. Smile

ISPs won't give you much PHP config freedom when you host your site anyway.

If you're not using SQL or have no other reason, I'm not sure why you'd be using dynamic URI anyway.
If the design of the dynamic URI is good, $_POST will supply all the form input you need.

It's best not to have queries in URI's. The Search engines won't thank you for it.
Think XML and you'll be half way there.

Dynamic Apache/PHP (DHTML) is really huge and there's so many ways to skin this cat that the RSPCA would have me long before I finished.

An old Apache/PHP/MySQL book may be available on trade me at a reasonable price. None of this technology is new.


:edit: How'd I become a master Geek? Someone is messing with the porridge in my head.







50 posts

Geek


  Reply # 75757 24-Jun-2007 09:59

Okk well i will not use ?op=home at the end anymore sounds a little to hard for my liking. Here is a second question, Whats a good web host i can use?? this is for a CSS website and i will be put a forum on it. I was going to go with dot5hosting but they sent me a e-mail asking for a photocopy of the credit card i used so i was like umm i am not sending them that. I looked up online about them and some of them said they are not good to host with. So any one got some good hosting plans i can use?

208 posts

Master Geek


Reply # 75972 26-Jun-2007 14:58
Send private message

I've found netneeds.co.nz supports a good range of hosting plans for both Linux and Microsoft servers.

Their plans are competitively priced and support all the usual suspects of MySQL, MS-SQL,  ASP, PHP and Perl etc.

Bandwidth and disk storage is capped depending on which plan you use.

I’ve hosted stuff with them for close to two years and never had any problems.

When I have had to contact them, I found they respond in a timely fashion and have been able to address any issues I’ve had effectively.

I am not affiliated with Netneeds and if I wasn’t happy with their service…. I’d recommend someone else.

Tom

6 posts

Wannabe Geek
Inactive user


  Reply # 76138 27-Jun-2007 18:37
Send private message

hmm i've had some experience over PHP, And Html and ftp coding, its quite easy when you start getting into it, to make it easier try playing around with it and uploading your scripts to a website that enables PHP. or whatever you are using once your've learnt the basic of using it, try building up ur skills or going to other websites to help

not sure if this helps but. yeah

3 posts

Wannabe Geek


  Reply # 77787 11-Jul-2007 19:19
Send private message

You'll want to write a navagation system for your index page.

Here's what I've thought up:

<?php
$pages_array = array(
                        'url_variable' => 'page.php'; # ?op=home, "home" is the url_variable, page.php is the page.
                        'url_variable2' => 'page2.php';
                      );

$page = $_GET['op'];

if (in_array($page) AND file_exists($pages_array[ $page ]))
include $pages_array[ $page ];
?>

I haven't tested it, but it should work.

Create new topic

Twitter »

Follow us to receive Twitter updates when new discussions are posted in our forums:



Follow us to receive Twitter updates when news items and blogs are posted in our frontpage:



Follow us to receive Twitter updates when tech item prices are listed in our price comparison site:



Geekzone Live »

Try automatic live updates from Geekzone directly in your browser, without refreshing the page, with Geekzone Live now.



Are you subscribed to our RSS feed? You can download the latest headlines and summaries from our stories directly to your computer or smartphone by using a feed reader.

Alternatively, you can receive a daily email with Geekzone updates.