Code:
<?php
/***************************************************************************************************
adjust order by rearranging in both arrays
add or delete as desired but then must also adjust .htaccess and add/delete pageContent/[name].txt
For site to "process" a page as a full-fledged member, specify it in [root]\page.php.
On 12/29/2010 18:04, Allan Marain wrote:
> How do I put text in the left hand margin?
trivial:
if you want the same extra text on every page, copy the lines below to the end of
includes\menu.inc.php and fill in the blank line after the <p> with whatever text you want, multiple
lines ok (don't copy the start/end of course)
?>
<p>
</p>
if instead you want text on only one page, copy this in, and then change the ### to match the value
of the $here variable on the page you want it for (which is the same as the items in the $menuLinks
array)
if ( $here === '###' ) {
?>
<p>
</p>
<?php
}
if you want various text on various pages, copy the above lines again below the set above (as many
times as you need to) but this time write elseif instead of if at the beginning, like this:
elseif ( $here === '@@@' ) {
Michael
***************************************************************************************************/
$menuItems = array(
'Home',
'Allan Marain',
'Edward J. Byrne',
'Case Evaluation',
'Radio Promo',
'Contact Us',
'Possession',
'Distribution',
'Drivers Licenses',
'Expungements',
'Stopped by Police',
'Jersey Justice',
'The Twilight Zone',
'Dangerous Drugs',
'High Links',
'About Marijuana',
'Directions',
'Parking',
);
$menuLinks = array(
'index',
'allanqual',
'byrnequal',
'quest',
'http://www.NJMarijuana.com/audio/njpot.mp3',
'contactus',
'possession',
'intent',
'http://www.NJDriversLicenses.com',
'http://www.NJExpungements.com',
'arrested',
'busted',
'76FR40552',
'drugs',
'resources',
'history',
'http://maps.google.com/maps?f=q&hl=en&q=100+Bayard+Street,+New+Brunswick+NJ+08901-2165',
'http://www.njnbpa.org/parking-locator/',
);
if ( $menuType === 'button' ) echo '<br />'; // adjust vertical start position on left margin
menu
$menuCount = count( $menuItems) ;
for ( $i = 0; $i < $menuCount; $i++ ) {
if ( $menuItems[$i] ) {
echo '<a ';
if ( $here === $menuLinks[$i] ) echo 'class="here" ';
else echo 'class="' . $menuType . '" ';
/************************************************************************
*
* Now we're going to test for local links. We do that by seeing whether the URL
* omits 'http'. If so, it's a local link, since we use relative addressing for local links
*
************************************************************************/
if ( strpos( $menuLinks[$i], 'http' ) === FALSE ) {
if ( $menuLinks[$i] === 'index' ) echo 'href="http://www.NJMarijuana.com'; // closing " is in
line 61 below
else echo 'href="http://www.NJMarijuana.com/page.php?here=' . $menuLinks[$i];
}
/**************************************************************************
*
* Now we're going to see whether we want to open a new window. The two pages
* where we do want to open a new window are the google maps page, and the
* parking authority page. Allan added a third new-window page on 10-13-12,
* viz the Radio Promo page.
*
***************************************************************************/
elseif
( strpos( $menuLinks[$i], 'google' ) !== FALSE
|| strpos( $menuLinks[$i], 'parking' ) !== FALSE
|| strpos( $menuLinks[$i], 'njpot' ) !== FALSE )
echo 'target="_blank" href="' . $menuLinks[$i] . '" onclick="popwin(\'' . $menuLinks[$i] . '\');
return false';
// other marain links need no special handling
else echo 'href="' . $menuLinks[$i];
echo '"> ' . $menuItems[$i] . ' </a>';
if ( $menuType === 'button' ) echo '<br />';
else {
/*****************************************************************************
Now we format the bottom menu
First do groupings, by category
Then examine individual entries
*****************************************************************************/
if ($menulinks[$i] === 'contactus'
|| $menulinks[$i] === 'http://www.NJExpungements.com'
|| $menulinks[$i] === 'history')
{echo 'br />';}
if ( $menuLinks[$i] === 'contactus'
|| $menuLinks[$i] === 'http://www.NJExpungements.com'
|| $menuLinks[$i] === '76FR40552'
|| $menuLinks[$i] === 'history'
|| $menulinks[$i] === 'http://www.njnbpa.org/parking-locator/'
|| strpos($menulinks[$i], 'njnbpa'))
{echo '<br />';}
else {echo ' | ';}
}
echo "\n";
}
}
if ( $menuType === 'button' ) {
if ( $here === 'resources' || $here === 'index' || $here === '76FR40552' ) {
if ( $here === 'resources' || $here === '76FR40552' ) {
?>
<br />
<br />
<br />
<br />
<br />
<font size="-1">
<a name="courts"></a>Municipal Courts<br />
Telephone Directories
<br />
<br />
<a href="#Hunterdon">Hunterdon County</a><br />
<a href="#Middlesex">Middlesex County</a><br />
<a href="#Monmouth">Monmouth County</a><br />
<a href="#Somerset">Somerset County</a><br />
<a href="#Warren">Warren County</a>
<br />
<br />
<a name="Hunterdon"></a>
Telephone Directory of Municipal Courts in Hunterdon County
<br />
<br />
Bethlehem and Bloomsbury Joint Municipal Court<br />
908-735-4559
<br />
<br />
<br />
<font size="-2"><a href="http://www.njmarijuana.com/page.php?here=resources">Return to
Top</a></font>
<a name="Middlesex"></a>
<?php
}
?>
<font size="-1">
<br />
<br />
Telephone Directory of Municipal Courts in Middlesex County
<br />
<br />
<br />
</font>
<font size="-2"><a href="http://www.njmarijuana.com/page.php?here=resources">Return to
Top</a></font>
<br />
<br />
<?php
if ( $here === 'resources' || $here === '76FR40552' ) {
?>
<a name="Monmouth"></a>
Telephone directory of Municipal Courts in Monmouth County
<br />
<br />
Aberdeen Municipal Court<br />
732-583-4200
<br />
<br />
<br />
<br />
<font size="-2"><a href="http://www.njmarijuana.com/page.php?here=resources">Return to
Top</a></font>
<br />
<br />
<a name="Somerset"></a>
Telephone Directory of Municipal Courts in Somerset County
<br />
<br />
Bedminster Municipal Court<br />
908-212-7020
<br />
<br />
<br />
<br />
<font size="-2"><a href="http://www.njmarijuana.com/page.php?here=resources">Return to
Top</a></font>
<br />
<br />
<a name="Warren"></a>
Telephone Directory of Municipal Courts in Warren County
<br />
<br />
Allamuchy Municipal Court<br />
908-852-6667
White Municipal Court<br />
908-475-4827
<br />
<br />
</font>
<font size="-2"><a href="http://www.njmarijuana.com/page.php?here=resources">Return to
Top</a></font>
<?php
}
}
elseif ( $here === 'arrested' ) {
?>
<p>
<font size="-2">
The policeman is <i>not</i> your friend. The policeman is a soldier in the “War Against
Drugs,” which is <i>really</i> a war against citizens. Do not try to talk your way out of an
arrest. Your “friendly” police officer is asking you questions in order to obtain
answers to use against you in court. Whatever you say can only hurt you. It will not improve your
situation.
<br />
<br />
To explore this subject in more depth, visit the web site of the <a
href="http://www.flexyourrights.org/" target="_blank">Flex Your Rights</a> Foundation. And
remember...
<br />
<br />
“Even a fish would not get caught if he kept his mouth shut.”</font>
<?php
}
elseif ( $here === 'allanqual' ) {
?>
<br />
<font size="-1">
<br />
<br />
Reflections of Allan Marain in Municipal Court:
<br />
<br />
As I sit in municipal court before my clients' cases are called, I watch with frustration and
to have the benefit of that experience.
<br />
<br />
Call them.
</font>
<?php
}
elseif ( $here === 'drugs' ) {
echo '<p><font size="-1">At one time, proclaiming that the earth circled the sun could earn a
of that day.</font></p>'
?>
<?php
}
}
Bookmarks