msimonds 0 Newbie Poster

Was wondering if you could take a look at the attached code.

I have a form that is making a call back to the database and populating search form for parts. As you type in parts, it renders choices (screenshot2 attached). You can then click on a choice and it populates the text box and a button also renders.

You can actually test the script: <URL SNIPPED>

Start typing in "DS12" and then click on one, you will see what I mean (screenshot1 attached).

What I want to do is take the $_GET and the new part number in the form to another script, right now just putting it into an array. I have a javascript function that sets up the form, called setpartno:


product_search.php

<?php
echo '<pre>' . print_r($_GET, true) . '</pre>';
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN">

<html>
<head>
    <title></title>
    <style type="text/css">
    /* ---------------------------- */
    /* CUSTOMIZE AUTOSUGGEST STYLE  */
    #search-wrap input{width:400px; font-size:16px; color:#999999; padding:6px; border:solid 1px #999999;}
    #results{width:260px; border:solid 1px #DEDEDE; display:none;}
    #results ul, #results li{padding:0; margin:0; border:0; list-style:none;}
    #results li {border-top:solid 1px #DEDEDE;}
    #results li a{display:block; padding:4px; text-decoration:none; color:#000000; font-weight:bold;}
    #results li a small{display:block; text-decoration:none; color:#999999; font-weight:normal;}
    #results li a:hover{background:#FFFFCC;}
    #results ul {padding:6px;}
    </style>
</head>

<body>
    <h4>Your current Product for this opportunity is <?php echo $_GET['name']; ?></h4><!-- AJAX AUTOSUGGEST SCRIPT -->
    <script type="text/javascript" src="lib/ajax_framework.js">
    </script>

    <div id="search-wrap">
        <h2>Search for new product</h2><input name="search-q" id="search-q" type="text" onkeyup="javascript:autosuggest()"> 

        <div id="results"></div>
    </div><script type="text/javascript">
    function setpartno(partno) {
    document.getElementById('search-q').value = partno;
    var e …
msimonds 0 Newbie Poster

I was wondering if maybe someone could shed a light on something for me.

I am performing the same SELECT Statement from Oracle on two servers via a simple export script.


Server one:

My Localhost
Apache/2.2.0 (Win32) PHP/5.1.2 from a RAW field and it is returning the ascii characters, which is what I am trying to do. So this script is performing the extract correctly


The data is being extracted from one table, two rows:
Row one is RAW
Row Two is VARCHAR2

Data in the CSV file is being extracted to a CSV file
Extract is:
row one > 000000000000121C
row two > Sanmina SCI

Server Two:
Apache/2.0.52 (Red Hat) PHP/5.2

Data in the CSV file is being extracted to a CSV file
Extract is:
row one >
row two > Sanmina SCI

I understand that row one is being extracted is a binary field but I want the extraction to work exactly as my localhost. Is it something in the PHP.ini file or do I need to compile PHP in a different way. I thought that it had to do with mbstring.


Has anyone ever incurred this before or can someone please shed some light on this!
TIA

Mike
Dallas Semiconductor

msimonds 0 Newbie Poster

acutally i think that I am getting somewhere:

RewriteRule ^image([0-9]*)-rantgirl([0-9]*).html  showimage.php?i=$1&c=$2 [L,NC]

This URL works for it, i just want to make sure that I am getting somewhere

http://www.sportsrant.com/gallery/image1453-rantgirl44.html

Dani do you see any problems with that code so far

Mike

msimonds 0 Newbie Poster

would something like this be even close:

RewriteRule ^showimage-([1-9][0-9]*)-rgom-([1-9][0-9]*).html  showimage.php?i=$1&c=$2
msimonds 0 Newbie Poster

Dani

Could you look into this if you had time, probably would not take that long for you.

For the higher level URL's to get into the gallery system, I have this in my .htaccess:

RewriteEngine On

RewriteRule ^index.html index.php [L,NC]
RewriteRule ^rantgirl([0-9]+).html$ index.php?rgom=$1 [L,NC]
RewriteRule ^rgom([0-9]+)-(.*).html$ browseimages.php?c=$1 [L,NC]

I am trying to mod_rewrite the indivudual pictures for each gallery. If i had the following URL's, how could I mod_rewrite them

http://www.sportsrant.com/gallery/showimage.php?i=1399&c=46

it is based off of the i=#### and the &c=##. the I being the picture number and the C valure being the album number.

I have donated to this site before and will do it again if you can help me out (even if You cannot figure this one out :cheesy: )

Regards,
Mike
Sportsrant.com

msimonds 0 Newbie Poster

Dani has given me permission to post this here


I co-developed a flash poll sytem that uses php/mysql for the anyone to download

IF you go to my site: http://www.sportsrant.com ou can see it in action on the right side or http://www.uoptoday.com, you can see it in action on the left side. Click on the vote button after you choose and see what it does.

You can download it from here, it has 3 skins and the .fla source to modify if you know how to use flash

http://www.freeimagebrowser.com/trk.php?fileID=29

Please let me know what you think!

Thanks
Mike

msimonds 0 Newbie Poster

that latest fix is the perfect fit and everything works as you posted. I REALLY appreciate your dedication and hard work. For people that want to have SEO type forums, You're an angel!!


Mike :mrgreen:

msimonds 0 Newbie Poster

I sent this email to another VB member here to see one problem with this tweak

he only thing that gets me about this is from the forums home page! (EXAMPLE)

This link here: http://www.sportsrant.com/forums/newpostinthread3501.html takes you to the latest thread like it should: http://www.sportsrant.com/forums/showthread.php?p=58579#post58579 and I do not believe this is good for SEO! If you go into that forum, even on your site, and click on http://www.sportsrant.com/forums/thread3501.html which is the same post and actually goes to the thread. Do you understand where I am coming from! Can this be fixed or tweaked to work, there has to be away. It will make it even more SEO!!

msimonds 0 Newbie Poster

acutally ma'am i was able to get this to work! It works perfectly and this is an awesome modification. The only question that I have is
when you click on this link (example)

http://www.sportsrant.com/forums/newpostinthread3503.html

then it should go to that URL, instead is goes to the regular php post, but it goes to:

http://www.sportsrant.com/forums/showthread.php?p=58619#post58619

Is there anyway to change that also!!


Mike

msimonds 0 Newbie Poster

I left a response over in your mod_rewrite thread! I hope you can help, I also contacted you on AIM from sportsrant2002

msimonds 0 Newbie Poster

I tried this and joined here after your post at seoforums. I need your help. There were a few changes from your vb 3.0.1 to vb 3.0.3.

I put the changs in that you states through your steps. First off thanks for the post and the mod, it is outstanding. I was wondering if you could help me! Is there anyway that you would be willing to look at my test forums and tell me what is wrong with what I did

Mike

http://www.sportsrant.com/testforums


this is what my htaccess file looks like!

RewriteEngine on
Options +FollowSymLinks
RewriteRule ^thread([0-9]+).html$ showthread.php?t=$1 [L]
RewriteRule ^lastpostinthread([0-9]+).html$ showthread.php?goto=lastpost&t=$1 [L]
RewriteRule ^newpostinthread([0-9]+).html$ showthread.php?goto=newpost&t=$1 [L]
RewriteRule ^f([0-9]+)-(.*).html$ forumdisplay.php?forumid=$1 [L]

msimonds 0 Newbie Poster

I could not find a great place to post!!! I wanted to say hi to everyone and I can see that this is a great forum. I am mainly here to learn the vbulletin mod_rewrite, which i tried on my test forums and I need some help


Thanks
Mike