Search Results for 'test'
-
Search Results
-
Hello, I have this code (which comes from another support thread here) on my front-page.php:
<table id=”highest”>
<?php $top_topics = bb_top_topics(); ?>
<?php foreach ( $top_topics as $topic ) : ?> // line 70
<tr<?php topic_class(); ?>>
</td>
<td class=”num”><div class=”rating-holder”><?php bb_rating();?>
<span class=”count”><?php bb_rating_count(); ?>
</span>
</div>
</td></tr>
<?php endforeach; ?>
</table>
And under it the code for latest topics.
It gives me this error:
Warning: Invalid argument supplied for foreach() in /home/home1/novapojistovna_cz/public_html/www/bbpress/bb-templates/kakumei/front-page.php on line 70
Can anybody help, please. Don’t quite understand what is wrong
Thanks
Hi all!
I run wordpress 2.6 at phonereport.info. I tried installing bbPress 1.0 Alpha so that it could integrate with WordPress, but just as I concluded the installation successfully, I get the following error:
‘Parse error: syntax error, unexpected T_STRING in /home/nokisat7/public_html/phonereport.info/test/bbpress/bb-config.php on line 20’
Line 20 is the following:
‘// the value of their equivalent keys in the WordPress file wp-config.php’
Here is the installation log, I changed the password:
‘Referrer is OK, beginning installation…
>>> Setting up custom user table constants
Step 1 – Creating database tables
>>> Modifying database: nokisat7_bbpress (localhost)
>>>>>> Table: bb_forums
>>>>>>>>> Creating table
>>>>>>>>>>>> Done
>>>>>> Table: bb_meta
>>>>>>>>> Creating table
>>>>>>>>>>>> Done
>>>>>> Table: bb_posts
>>>>>>>>> Creating table
>>>>>>>>>>>> Done
>>>>>> Table: bb_terms
>>>>>>>>> Creating table
>>>>>>>>>>>> Done
>>>>>> Table: bb_term_relationships
>>>>>>>>> Creating table
>>>>>>>>>>>> Done
>>>>>> Table: bb_term_taxonomy
>>>>>>>>> Creating table
>>>>>>>>>>>> Done
>>>>>> Table: bb_topics
>>>>>>>>> Creating table
>>>>>>>>>>>> Done
Step 2 – WordPress integration (optional)
>>> WordPress address (URL): http://phonereport.info/
>>> Blog address (URL): http://phonereport.info/
>>> WordPress cookie keys set.
>>> WordPress “auth” cookie salt set from input.
>>> WordPress “logged in” cookie salt set from input.
>>> Fetching missing WordPress cookie salts.
>>>>>> WordPress “secure auth” cookie salt not set.
>>> User database table prefix: wp_
>>> User database name: nokisat7_wrdp9
>>> User database user: nokisat7_forum
>>> User database password: something
>>> User database host: localhost
>>> User database character set: utf8
Step 3 – Site settings
>>> Site name: PhoneReport test forum
>>> Site address (URL): http://phonereport.info/test/bbpress/
>>> From email address: only.meraj@merajnet.com
>>> Key master role assigned to existing user
>>>>>> Username: admin
>>>>>> Email address: only.meraj@merajnet.com
>>>>>> Password: Your existing password
>>> Description: Just another bbPress community
>>> Forum name: PhoneReport test forum
>>>>>> Topic: Your first topic
>>>>>>>>> Post: First Post! w00t.
>>> Key master email sent
Installation complete!’
Please let me know what else you wish to have.
There are two different databases: one for the wordpress installation, the other for bbpress.
Thank you in advance, and keep up the good work!
Topic: reCAPTCHA for bbPress
I wrote a plugin to add reCAPTCHA to user registration page. (It’s inspired by _ck_’s Human Test.)
I’ve submitted request to add it to the plugin repository, however 1) the submission form didn’t have any feedback, so I ended up with two identical requests, 2) I didn’t realize you have to put the whole readme.txt to description field of this form. Could someone fix this, and write at least a few sentences describing the submission process?
Anyway, you can download it from http://www.codingrobots.com/files/bb-recaptcha.zip
IMPORTANT: You must get an API key from the reCAPTCHA project to use it. See readme.txt.
Tested under 1.0-alpha1, may not work with previous versions on some PHP deployments.
See how it works here: http://forum.codingrobots.com/register.php
Comments and code review are welcome!
I’ve added a “geo” field to the topics table that contains latitude and longitude data for each topic. The topics table now contains lat/lng from different cities all over the US.
I’ve modified forum.php to take latitude and longitude GET parameters to use as a “center.” Then I select topics within range of X miles and order by distance from “center.”
To hack this in I wrote a new function in classes.php called generate_geo_topic_sql. This worked enough so that I can test my idea, but its not a long term solution.
So now I need to somehow integrate this query into generate_topic_sql. I still want to retain the original functionality, but just create a different view if I’m using a “center” point.
This is the query. You can not run multiple statements at once in PHP so each of these queries need to be executed separately.
SET @center = GeomFromText(‘POINT(” . $lng . ” ” . $lat . “)’);
SET @radius = 1;
SET @bbox = CONCAT(‘POLYGON((‘,X(@center) – @radius, ‘ ‘, Y(@center) – @radius, ‘,’,X(@center) + @radius, ‘ ‘, Y(@center) – @radius, ‘,’,X(@center) + @radius, ‘ ‘, Y(@center) + @radius, ‘,’,X(@center) – @radius, ‘ ‘, Y(@center) + @radius, ‘,’,X(@center) – @radius, ‘ ‘, Y(@center) – @radius, ‘))’);
Then this was the “hack” query that I wrote to get it to work. I dumped the SQL from the original generate_topic_sql and grafted on what I needed.
SELECT t.*,SQRT(POW( ABS( X(t.geo) – X(@center)), 2) + POW( ABS(Y(t.geo) – Y(@center)), 2 )) AS distance FROM bb_topics AS t WHERE t.topic_status = ‘0’ AND t.topic_sticky != ‘2’ AND t.forum_id = ‘” . $this->query . “‘ AND Intersects( t.geo, GeomFromText(@bbox) ) AND SQRT(POW( ABS( X(t.geo) – X(@center)), 2) + POW( ABS(Y(t.geo) – Y(@center)), 2 )) < @radius ORDER BY distance ASC LIMIT 3
The problem is that paging does not work (and a few other things) in my hackjob function. I need to find a way to integrate this into the regular function so that I can maintain all the functionality.
Any suggestions?
Hi,
bbpres 0.9.0.2
Im exhausted looking for a solution so i post, after a clean install in hostgator, when I click on Latest Discussions ADD NEW link, while not logged, I get a link similar as:
http://www.domain.com/forum/bb-login.php?re=http%3A%2F%2Fwww.domain.com%2Fforum%2F%3Fnew%3D1
and after clicking on it: I got a WordPress 404 not found page.
I have tried adding and .htaccess in my bbpress directory with Options +MultiViews
I have turned off-on pretty permalinks,
I have installed a wordpress 404 fixer plugin,
But nothing works,
Only if is logged a user the ADD NEW link works.
Please helpme I am on a deadline weekend.
best regards
monica
In forum.php and front-page.php, the latest poster for each topic is identified. Is it possible to also identify the first poster– ie the person who started the thread and perhaps also when the thread was started? After sifting through code for several hours, I’m not sure if I’m overlooking something, or if I simply cannot find something that is not there. Thanks.
Topic: Problem with sticky topics
Hi there,
My bbPress forum (0.9.2) has been theme and databased intergrated, I’ve just decided to test sticky topics, and this occurs on a sticky topic:
http://www.james-blogs.com/forum/topic.php?id=3
What is this [sticky] code doing, Is this meant to be how a sticky topic is identified to someone or is broken bbcode?
Regards,
James