At 10:00 AM -0700 8/5/09, Allen McCabe wrote:
-snip-
If this sounds like something you are familiar with (former issues and
whatnot) please let me know what I'm doing wrong.
Try this:
http://sperling.com/examples/include-demo/
If you follow what's given there, you'll be further along on incl
On Wed, Aug 05, 2009 at 02:55:07PM -0700, Ben Dunlap wrote:
> > In my navigation.php include file, I had if ($page = about) echo href
> > I changed it to if ($page == about) echo and it suddenly
> worked! Imagine
> > that...
>
> Another good case for putting the variable on the right side
Yes, that's a golden rule for a bug free code.
The rule shoudl be something like this...
Whenever you have a constant value evaluated to a non-constant value
put them in the left side of the expression.
if( 'constant' == $non_constant )
echo ' variables has that name for anything ';
if( fals
> In my navigation.php include file, I had if ($page = about) echo href
> I changed it to if ($page == about) echo and it suddenly worked! Imagine
> that...
Another good case for putting the variable on the right side of "==":
if ("about" == $page)
Then if you mis-type "==" as "=", PH
I just wanted to let know I figured out my last issue (last as in, for now).
In my navigation.php include file, I had if ($page = about) echo href
I changed it to if ($page == about) echo and it suddenly worked! Imagine
that...
Thanks all for you help, you are celebrities in my book now.
You are using a value-filled array as a key-filled. Try this snippet
and look the results...
$pages = array('about' , 'services', 'portfolio', 'contact');
$page = array_key_exists( 'page', $_GET ) ? $_GET[ 'page' ] : 'about';
/*if*/ false === array_search( $page, $pages, true ) && (
$page
Okay, I see how href="?page=contact" would work, and I do indeed have only
one file (which loads includes), but it still is not working. Clicking a
link, be href=?page=contact, href=?page=services, whatever, it still loads
the page with the ?page=whatever attached to the URL, but it is not
subsitut
On Wed, 05 Aug 2009 20:19:00 +0300, Allen McCabe
wrote:
Sure.
When I load my site, default.php loads ( displaying:
http://uplinkdesign.hostzi.com/ in the browser as expected). $thisPage is
set to "about" via:
in the tags.
I am seeing this:
The first 2 includes work just fine, loading
I think you are looking for something like this:
$page = array_key_exists( 'page', $_GET ) ? GET['page'] : 'index';
Then you MUST sanitize the $page variable.
I often use the querystring to wrapp the module you are requesting:
www.example.org/?path/to/molude (note that .htaccess is required)
#
Sure.
When I load my site, default.php loads ( displaying:
http://uplinkdesign.hostzi.com/ in the browser as expected). $thisPage is
set to "about" via:
in the tags.
I am seeing this:
The first 2 includes work just fine, loading to proper middle section and
proper right-hand-side page conte
I'm having trouble understanding your description of the problem. Can you
tell us what you're seeing and what you expect to see?
Jerry Wilborn
jerrywilb...@gmail.com
On Wed, Aug 5, 2009 at 12:00 PM, Allen McCabe wrote:
> I am trying to generate pages by importing content in includes, and using
On Tue, Sep 30, 2008 at 1:07 PM, Eric Butera <[EMAIL PROTECTED]> wrote:
> Don't forget people share links and find sites through lots of random
> ways. It's nice to have such things.
Oh yes, I am moreso for the "back to home" style myself. A deep link
won't benefit from the "this is how you got
On Tue, Sep 30, 2008 at 3:54 PM, mike <[EMAIL PROTECTED]> wrote:
> Also remember there are two styles of breadcrumbs: those which follow you
> around the site and create a path of your previous pages (like a true
> breadcrumb) or the more standard path-back-to-home hierarchial style. It
> doesnt ma
Also remember there are two styles of breadcrumbs: those which follow
you around the site and create a path of your previous pages (like a
true breadcrumb) or the more standard path-back-to-home hierarchial
style. It doesnt make much sense to recreate the browsers back button
functionality
On 30 Sep 2008, at 18:23, tedd wrote:
At 4:27 PM +0100 9/30/08, Stut wrote:
As examples check out the following pages (under the orange bar)...
http://uk.freeads.net/
Stut:
I can understand:
Travel >> Holidays
Because the user moves to the "Holidays" page from the "Travel"
page. In fact,
At 4:27 PM +0100 9/30/08, Stut wrote:
As examples check out the following pages (under the orange bar)...
http://uk.freeads.net/
Stut:
I can understand:
Travel >> Holidays
Because the user moves to the "Holidays" page from the "Travel" page.
In fact, there's no way to get to the "Holidays"
On 30 Sep 2008, at 16:33, Alain Roger wrote:
Interesting but how to make this hierarchy ?
this i do not know in PHP :-(
where can i find code examples ?
This depends too much on how your site is structured for me to give a
useful answer.
As I said in my reply "If your site can't figure out
Interesting but how to make this hierarchy ?
this i do not know in PHP :-(
where can i find code examples ?
On Tue, Sep 30, 2008 at 5:27 PM, Stut <[EMAIL PROTECTED]> wrote:
> On 30 Sep 2008, at 16:04, Alain Roger wrote:
>
>> a lot of web sites propose a locationbar (something like dynamic map sit
On 30 Sep 2008, at 16:04, Alain Roger wrote:
a lot of web sites propose a locationbar (something like dynamic map
site)
to end user when they are browsing the website.
usually i looks like that:
Home > Products > Software > Operating System > Windows XP
User can come back to a previous parent
[snip]
a lot of web sites propose a locationbar (something like dynamic map
site)
to end user when they are browsing the website.
usually i looks like that:
Home > Products > Software > Operating System > Windows XP
User can come back to a previous parent node by just clicking on the
name,
for ex
On Sat, January 27, 2007 8:42 am, koen wrote:
> How to creat the effect of the explorers back and forward buttons in
> php?
Something like this, except I almost for sure have a one-off error or
got the 'push' confused with 'shift' as I always do...
$current_page){
$last_page = $history[$curr
koen wrote:
How to creat the effect of the explorers back and forward buttons in php?
It's a javascript issue, using the javascript history object.
--
_
Myron Turner
http://www.room535.org
http://www.bstatzero.org
http://www.mturner.org/XML_PullParser/
--
PHP General
[snip]
How to creat the effect of the explorers back and forward buttons in
php?
[/snip]
Since PHP is server side you would have to use Javascript to do this.
See
http://www.comptechdoc.org/independent/web/cgi/javamanual/javahistory.ht
ml
--
PHP General Mailing List (http://www.php.net/)
To un
Thanks for your reaction,
You are right about your conclusion how I think the code should work. I am
indeed trying to run the script off one server (my_domain1) and then
attempting to "feed" the function a directory structure off another server
(my_domain2).
I suppose the function opendir() only
The function is correct, BUT, it looks like you are trying to run this
script off one server and then attempting to "feed" the function a
directory structure off another server.
Your code will work "as-is" if you run the script off my_domain2, but it
won't work if you run it off my_domain asking f
there are numerous posts on the list regarding this subject, I will give
some code examples, I hope this helps.
\n";
}
echo "
";
if ($pos_prev >= 0)
echo "
Back
";
echo "
Home
";
if ( $pos_next < $product_count )
echo "
Next
";
echo "
";
?>
simple, no complica
26 matches
Mail list logo