
floridaflatlander
-
Posts
671 -
Joined
-
Last visited
-
Days Won
1
Posts posted by floridaflatlander
-
-
I mean like test
... while($row = mysql_fetch_array($result)){ if($row['user_group_id'] <= 2){ $multiplier = 1; } if($row['user_group_id'] == 6){ $multiplier = 2; } if($row['user_group_id'] == 7){ $multiplier = 3; } if($row['user_group_id'] == { $multiplier = 4; } $totalshares = ((($row['activity_blog']*$multiplier)/2)+(($row['activity_comment']*$multiplier)/10)); $set_shares=mysql_query("UPDATE phpfox_user SET bod_shares=$totalshares WHERE profile_page_id=0"); echo " User id: ".$row['user_id']." multiplier:".$multiplier." User group:".$row['user_group_id']." - blog:".$row['activity_blog']." - comment:".$row['activity_comment']." totalshares= ".$totalshares.""; echo "<br />"; } // echo for test echo "Totalshares: $totalshares"; ?>
I allways put echo "Whatever: $whatever"; so at least something prints and lets me know the echo is working.
-
but doesn't work on this page where I need it to work, this is the main line here:
Then go over your code(not just the echo statement) very carefully after you move it, something is missing.
-
Place an echo for $totalshares outside your loop and see what or if $totalshares has value.
-
Look at the source code and see what it has "or doesn't have" as a link for the image.
-
Try
echo "<a href=".$row['url']."><img class="image1" src=".$row['image_path']." alt=".$row['summary']."></a><br />";
-
Were is you destination file, it's not here <a href=\'\'>. This should be something like <a href="http:\\www.webpage.com" >. have you named columns correctly?
Put the echo statement you're using now on here.
-
This is what it shows in the browser source code, weirdly no link?
<a href=\'\'><img class='image1' src=\'cutouts/search/image1.png\'
So why are there single quotes and no double quotes, why are the slashes in your code? Play with it.
-
You add double quotes for the html not php and you have to escape them for php, your going to have to play with it but basiclly
so it would be something like href=\"{$row['url']}\" and the same for src and alt
I use single quotes so echo '<a href='.$row['url'].'></a>';
Like I said, play with it.
-
I don't see any added and escaped quotation marks
echo "<a href='{$row['url']}'><img class='image1' src='{$row['image_path']}' alt='{$row['summary']}'> </a><br />";
-
Looks like you need dounle qoutes in there, you'll have to escape them.
href=\"{$row['url']}\" and scr=\"xxxx\" and alt=\"xxxx\"
-
If I had only one pic per category I'd use something like
id | cat_name | image_path | url | summary or what ever |
echo '<a href="'.$row['url'].'"><img class="image1" src="'.$row['image_path'].'" alt="'.$row['cat_name/summary or any column you want'].'></a><br />';
or
echo '<a href="'.$row['url'].'"><img class="image1" src="'.$row['image_path'].'" alt="'.$row['cat_name'].' - '.$row['summary or any column you want'].'></a><br />';
-
Could I put property id? because each property has its own unique id?
It lookes like you have two unique ids. You probably only need one. Is id an auto_increment? Anyway as long as they're unique you can use them.
Okay we have
id | property_id | image_path
id | cat_name
so you could do
echo '<a href="xxxx.com/category.php?cat='.$row['id or property_id'].'"><img class="image1" src="'.$row['image_path'].'" alt='.$row['cat_name or any column you want'].'></a><br />';
-
I see you have your full path in the table so I'd used
echo '<a href="xxxx.com/category.php?cat='.$row['cat_id'].'"><img class="image1" src="'.$row['image_path'].'" alt='.$row['summary'].'></a><br />';
-
What would I put in "xxxx.com" because the links are going to all be different depending on which image is displayed.
I was assuming you have a table like
cat_id | cat_name | summary | image_name |
1 | dogs | dogs are great |dogpic.jpg
2 | cat | cats are better | catpic.jpg
so xxxx.com/category.php?cat='.$row['cat_id']. would become xxxx.com/category.php?cat=1 and it would be a picture of a dog and a link to the dog category.
It would look more like this if I did it
echo '<a href="xxxx.com/category.php?cat='.$row['cat_id'].'"><img class="image1" src="/image-folder-path/'.$row['image_name'].'" alt='.$row['summary'].'></a><br />';
and your source would end up like this
<a href="xxxx.com/category.php?cat=1"><img class="image1" src="/image-folder-path/'docpic.jpg"' alt="dogs are great"></a><br />
-
Say you have a category table that has all your cats info including a column for the image location, we'll call it image_path.
run a sql statement to display the categories image_path and cat_id
while (this stuff) {
echo '<a href="xxxx.com/category.php?cat='.$row['cat_id'].'"><img class="image1" src="'.$row['image_path'].' alt='.$row['summary'].'></a><br />';
}
-
You have
echo "<a href="xxxx.com"><img class='image1' src='{$row['image_path']}' alt='{$row['summary']}'></a><br />";
What do you mean their own unique link
-
...if they get your config file, the order you hash the pw & salt and your tables(salt & hashed passwordsdb) you have ... problems.
5. ......, instead use
sha1(md5($password).$password)
. It's hard to explain why without getting deep into how hash algos work. There's plenty of info out there if you want to dive deeper.Whats the difference?
-
You can try the poor mans way, $display_block = FALSE; somewhere about the var in question. I'd put it above $db_name
-
Here is a very useful link http://onlinebusiness.about.com/od/searchengineoptimization/a/search-ranking.htm but when all is said and done it all boils down to content. To me all 10 of these factors hinges on content one way or another.
You don't need different names web site names, just the content that people are looking for, also as a note people say key words but many times they're talking about key phrases. Have them on your page, the higher up the better, Like tab title and an h1 title on the page that says Dallas Air Conditioning Service.
When someone clicks on my domain, which would come up on the search, instead of seeing the generic text,When someone searches for Dallas Air Conditioning Service, they'll see your page title like the one on the tab at the top here and they'll click it and it will go to your site.
Also get people that you do business with to link to your site using "Dallas Air Conditioning Service" not your company name.
-
I think wordpress allows you to add a general salt (the same one for everybody) on their config page. if you did this you could hash it and the password anyway you want, md5 then sha1 etc.
And yes if they get your config file, the order you hash the pw & salt and your db tables you have a sh*t pot full of problems.
-
This is a good link that someone on here pointed me to last year.
http://pbeblog.wordpress.com/2008/02/12/secure-hashes-in-php-using-salt/
Also I read last week that sha1 in the sql statement gives a greater range of hashes than in the php.
-
Put your url in here at http://validator.w3.org/ . It says you have 8 errors, 1 is no doc type and another says doc type does not allow style here.
This link and firefoxes firebug are handy tools.
-
I went here http://validator.w3.org/ and w3.org said you had 466 errors on that page.
Of course I didn't look at them but most are probably stuff that's repeated.
This is a good tool to use.
-
I'd go to the phpbb forums, this should be a standard problem for people moving a forum and you should have people there that could point you in the right direction.
For example, smf has a file repair_settings that walks you through many of the things you're talking about.
How to get the numeric time
in PHP Coding Help
Posted
I use a simple machines forum and want to combine a table I have and a smf table and I need the dates in a numberic format(like smf uses).
Sooo ... how do I get the time in a format like this 1336392447
Thanks