View Full Version : vbArticles v0.4 -- For your repository of Articles/Tutorials/FAQs etc.
UPDATES
version 0.4 is out
- Now allows for basic VBCODE input.
- Fixed somemore bugs.
Background
Required a section on my site to display articles/tutorials
No such hack in the Hacks Database
Decided to try my hand at it
ACKNOWLEDGEMENTS
This hack uses a lot of code from Arunan Sridharan's vB Links Directory v2.0 (https://vborg.vbsupport.ru/showthread.php?s=&threadid=44551&highlight=links+directory)
I use that hack too and was inspired to code something around that
A big thank-you must go out to him for coding the Links Directory in the first place (I merely modified much of the code to suit my needs for this hack)
Appreciation also goes out to Kars10 for aiding me in this hack
He coded the portion in version 0.3 on number of articles count as well as article hits count
He also suggested several template changes which have been incoporated into version 0.3
A great big special shout out to TheComputerGuy, 97cobracpe, dontpanic for stamping out the bugs with your fixes. Thanks guys :D
WHATS IT DO ?
This hack allows you to have a database of articles/tutorials etc on your site/forums.
FEATURES
AdminCP
Installer script
Admin options
View Categories
Edit Categories
Add Categories ( category name, category icon, category order, category description )
Delete Categories
Add new article ( title, description, author, date, content )
Edit article
Delete article
View ALL articles in database
Option in vB options to turn validation of articles on/off
Fully template based as to how you wish to display the articles,categories and main article home page.
Addition of articles accepts basic VBcodes
Member options
View Categories
Browse Categories
View articles
Submit new article
Submission of articles accepts basic VBcodes
INSTALLATION & UPGRADING
This Hack should work on ALL 2.2.x versions and v2.3.0
Please read the install_readme.txt file in the package for fresh installation instructions
IMPT: If you installed a previous version pls read the upgrade_readme.txt file carefully for upgrade instructions
HACK DOWNLOAD
Version 0.4 of this hack can be downloaded here (https://vborg.vbsupport.ru/showpost.php?s=&postid=408918)
ADD-ONS
i) Add-on for vbHome (https://vborg.vbsupport.ru/showthread.php?postid=409163#post409163)
ii) Add-on for ForumHome (https://vborg.vbsupport.ru/showthread.php?postid=409234#post409234)
iii) Add-on to enable only registered members to be able to view the article section (https://vborg.vbsupport.ru/showthread.php?postid=414057#post414057)
DEMO SITES
http://www.runaked.com/forums/articles.php ( running v0.4 ) - TheComputerGuy (https://vborg.vbsupport.ru/member.php?s=&action=getinfo&userid=116)'s site
http://www.mcseworld.com/forums/infocenter.php ( running v0.3 ) - dontpanic (https://vborg.vbsupport.ru/member.php?s=&action=getinfo&userid=35985)'s site
Feel free to submit your sites if u installed this hack so it can be listed as another live demo site
SUPPORT
I cannot promise any support on this as i am pretty new to this but I will try my best.
If you are using this hack , pls click the INSTALL (https://vborg.vbsupport.ru/misc.php?s=&action=install&threadid=54331) button
to be kept in the loop of any bug reports, add-ons and hack version updates.
Thanks everyone :)
Progress update : 27/10/2003
For next version : 0.5
Accommodated Features and Bug Fixes
Bugs Fixed
Post 202 ( bug fix )
Post 215 ( bug fix )
Post 226 ( bug fix )
Post 230 ( bug fix )
Posts 214-225 , 233-237 ( bug fix )
Feature Requests and other Additional Features that have been implemented ( completed )
- Category Icon upload
- Much easier navigation, less redundant navigation
- Posted By field for articles where the original author is different from the person who uploaded it
- In adding of article, no longer need to enter date of article, it is automatically added as a timestamp
- Adding of article in AdminCP easier
- Editing of article allows moving into another category if wrongly placed
- Easier management of View All Categories ( edit, delete, view articles in category, update order )
- Update order of categories now similar to vbulletin?s method
- Easier management of View All Articles ( edit, delete, view article )
- Author name automatically entered in AdminCP when adding article
- Cleaner code
- Print article , printer friendly.
- Email article to a friend link
- Ability to search articles by title, author and content
- Pagination of article ( pagebreak string set by admin )
- Pagination of articles under each category ( number of articles shown per page set by admin )
Features yet to be implemented
Post 229
I am trying to figure out how to put thumbnail images in front of the reviews. Like the categories currently have.
Post 213
Image lead-in to article
Ratings per article
Comments per article
1 level Subcategories
User group options
Category and article icon resizing
Feature requests that will be turned down and NOT implemented
Post 198
2. Make the "Content" field look more like the posting field in vBulletin.
3. In addition to allowing for vbCode, also have the vbcode buttons above the "Content" box
4. An option in the ACP to allow/disallow vbCode and HTML and have the suggestion #3 above show or don't show based on this setting.
Cinq : I will try to implement something else that is similar but not exactly like this. Hopefully WYSIWYG though.
Post 209
xHTML ?
Cinq : Not proficient enough, sorry.
Post 213
6) Copy an entire article or category (this is very helpful for using articles or cats as templates for future articles, or perhaps archiving old ones
10) XML RSS Feed output
Cinq : 10 - not proficient enough, sorry. 6 ? nah, don? be lazy :p
Post 213
7) Is it possible to select that a lead-in will link to an off-site article directly (by URL)
Cinq : think I'll skip this as well, may have copyright issues plus I'm lazy :p
Download hack here
Latest dated 01/08/2003.
All bugs and fixes in ALL posts before post 183 taken care of :)
kaotic
06-14-2003, 03:13 PM
I know that I'm admitting to myself how lazy I am if I install/utilize this hack... but I have no problem with that. :) Thanks, cing! Nice modifications.
gmarik
06-14-2003, 04:06 PM
Big thanks, this was what I was looking for a long time, great!
is it possible to add html codes ?
Deviant Mind
06-14-2003, 04:07 PM
This shoudl come in handy. I'll try it out on my test board later this afternoon
Katana Myronson
06-14-2003, 04:23 PM
Good job!
*clicks install*
DrkFusion
06-14-2003, 04:33 PM
Very nice job
Xyphen
06-14-2003, 04:51 PM
Very very nice, good idea too... good job!
TheComputerGuy
06-14-2003, 06:54 PM
Do ya think their would be anyway to take like the 5 newest ones and put those on a like the front page of vB Home?
But thank you so much for this hack, this rocks!!!
Kars10
06-14-2003, 07:06 PM
Exactly what ive been looking for, for a very very long time!!!! :)
Thanks so much buddy.
Kars
* Kars10 licks the install button for 10 min. ;)
gmarik
06-14-2003, 08:19 PM
Yesterday at 11:54 PM TheComputerGuy said this in Post #12 (https://vborg.vbsupport.ru/showthread.php?postid=409004#post409004)
Do ya think their would be anyway to take like the 5 newest ones and put those on a like the front page of vB Home?
But thank you so much for this hack, this rocks!!!
Where have you been lost? You said you'll skin it...
But a great idea ... :p
TheComputerGuy
06-14-2003, 08:26 PM
<a href="http://www.runaked.com/forums/articles.php" target="_blank">www.runaked.com/forums/articles.php</a>
Beta Testing right now...Tried to edit the articles I get this
Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /home/runaked/public_html/forums/admin/vbArticlesadmin.php on line 182
Also someone should point out that if you have the Links hack installed that you do not have to mod the adminfunctions file.
gmaik...Sorry had some personal stuff come up, should be finished soon!
iggy123
06-14-2003, 08:34 PM
Today at 10:26 PM TheComputerGuy said this in Post #15 (https://vborg.vbsupport.ru/showthread.php?postid=409029#post409029)
www.runaked.com/forums/articles.php
Beta Testing right now...Tried to edit the articles I get this
Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /home/runaked/public_html/forums/admin/vbArticlesadmin.php on line 182
Me too
Kars10
06-14-2003, 08:40 PM
Works like a charm here. :)
But one thing, can you make it that people can post there articles there (like in the linkscrpt)? Would make more sense i think.
I have not the time to add every article by myself.
Thanks in advance
Kars
TheComputerGuy
06-14-2003, 09:08 PM
I think you could make this work in the supermod or mod folder and just add a link yes?
DrkFusion
06-14-2003, 10:47 PM
Today at 03:54 PM TheComputerGuy said this in Post #12 (https://vborg.vbsupport.ru/showthread.php?postid=409004#post409004)
Do ya think their would be anyway to take like the 5 newest ones and put those on a like the front page of vB Home?
But thank you so much for this hack, this rocks!!!
Very easy. 2 Ways you can do this
1. Use an include, and include the top5new full url using something like include("http://domain.com/links.php?action=whatever4top5new");
2. Check how it is taken in the top5new action and copy the code put it into a new file, and make sure you can access global.php and functions.php and include it to your site, but I am guessing if you want to put it into your site you will have to do code modifications because i am sure you do not want the Links Directory Layout showing up on your front page :) If you do want the links dir page then use the 1st way.
kaotic
06-14-2003, 10:54 PM
Public Submissions/Validation Process would make this hack even perfecter! :p
DrkFusion
06-15-2003, 12:44 AM
Today at 07:49 PM cinq said this in Post #20 (https://vborg.vbsupport.ru/showthread.php?postid=409065#post409065)
In the article content i presume ? If so , yes.
Put the 5 latest articles on the articles home page shouldnt be a problem , will be included in the next version.
But as for putting it on the front page in vbHome , this i aint too sure as I havent tried vBhome yet.
Give me some time on this , but no promises , am new to this too ! :D
Thanks , your site is looking good , will add it to my post as a demo site :)
As for the error you got , I cannot seem to replicate it but it seems iggy123 is facing the same problem , will try my best to look into it.
Could you try deletion of an article ?
It will work, Arunan release a modification for vBhome at teckwizards.com that showed the linksdir categories, all you have to do is change the query around.
kaotic
06-15-2003, 02:35 AM
Sweet. Updated already. I'm glad I was too lazy to install it the first time. :p
UPDATES
version 0.2 is out
- Added category icon support
- Articles submission by registered members
- admin option of validation of submitted articles
Re-download the attached zip package and read the upgrade txt file carefully if upgrading from v0.1
For fresh installation , pls read the readme txt file contained in the zip package
ADD-ON 1
Was reading up at teckwizards.com (http://www.teckwizards.com/index.php?s=) with regards to integration this hack w vbHome as requested.
Came upon this thread (http://www.teckwizards.com/forum/showthread.php?s=&threadid=132&highlight=links+directory).
If going by Arunan's instructions, the following instructions should give you similiar result for having articles display on your vbHome portal page.
This add-on assumes you have vbHome installed.
Installation
STEP 1
Open the index.php from the vBhome hack, and find:
// latest threads
$threadbits = '';
$threadmaxnumber = '';
if ($threadmax!=0) {
$threadmaxnumber = "LIMIT $threadmax";
}
ABOVE that code ADD:
// vbArticles
$ebg = $DB_site->query("SELECT * FROM vbArticles_cat ORDER BY catname");
if ($DB_site->num_rows($ebg)) {
while ($myrow=$DB_site->fetch_array($ebg)) {
$hasattach=1;
$catid=$myrow["artcatid"];
$catname=$myrow["catname"];
$catdesc=$myrow["catdesc"];
eval("\$catlistbit .= \"".gettemplate('home_articlecatbit')."\";");
}
}
eval("\$vbhacats .= \"".gettemplate('home_articlemain')."\";");
Still in the index.php file find: (This will reduce your queries by 1 or 2)
$templatesused = 'home,home_articlebits,home_footer,home_header,hom e_headinclude,home_thread,home_threadbits,home_wel comeguest';
and REPLACE with:
$templatesused = 'home,home_articlebits,home_footer,home_header,hom e_headinclude,home_thread,home_threadbits,home_wel comeguest,home_articlemain,home_articlecatbit';
Save the index.php file
STEP 2
Create a new Template, and call it home_articlemain, put the following code in :
<table cellpadding="0" cellspacing="0" border="0" bgcolor="#555576" width="100%">
<tr>
<td>
<table cellpadding="4" cellspacing="1" border="0" width="100%">
<tr id="cat">
<td bgcolor="#606096"><smallfont><font color="#FFF788"><b>Articles</b></font></smallfont></td>
</tr>
$catlistbit
</table>
</td>
</tr>
</table>
<br>
Create another template and call it home_articlecatbit and put in this code :
<tr>
<td bgcolor="#13486D"><smallfont>
<b><a href="$bburl/articles.php?s=$session[sessionhash]&action=viewcat&catid=$catid">$catname</a></b><br>
$catdesc
</smallfont></td>
</tr>
STEP 3
Now open the home template from the vBhome template group, and find:
$advertisement
below it ADD:
$vbhacats
Not tested on my end
- If you have this working on your vbHome site , pls let me know your site URL so i can add it as a demo for this add-on.
Dean C
06-15-2003, 09:10 AM
Very nice hack :)
Kars10
06-15-2003, 10:00 AM
There is a small bug in it. In the recent articles section the date and author are not displaying.
search for:
eval("\$catlistbit .= \"".gettemplate('vbArticles_catbit')."\";");
}
}
$asb = $DB_site->query("SELECT * FROM vbArticles_content WHERE valid='1' ORDER BY artid DESC LIMIT 5");
if ($DB_site->num_rows($asb)) {
while ($myrow=$DB_site->fetch_array($asb)) {
$artid=$myrow["artid"];
$title=$myrow["title"];
$byline=$myrow["byline"];
eval("\$top5listbit .= \"".gettemplate('vbArticles_artbit')."\";");
}
}
replace it with:
eval("\$catlistbit .= \"".gettemplate('vbArticles_catbit')."\";");
}
}
$asb = $DB_site->query("SELECT * FROM vbArticles_content WHERE valid='1' ORDER BY artid DESC LIMIT 5");
if ($DB_site->num_rows($asb)) {
while ($myrow=$DB_site->fetch_array($asb)) {
$artid=$myrow["artid"];
$title=$myrow["title"];
$byline=$myrow["byline"];
$author=$myrow["author"];
$date=$myrow["date"];
eval("\$top5listbit .= \"".gettemplate('vbArticles_artbit')."\";");
}
}
Thanks
Kars
Thanks for the report Kars, updated the zip file with the neccesary changes. :)
Kars10
06-15-2003, 01:28 PM
No Problem cinq. :)
Kars10
06-15-2003, 01:40 PM
Maybe someone is interessted in displaying a Articles count on Forumhome...
Just search for:
// get newest member
above it place:
// Tutorials
$counttutorials = $DB_site->query_first("SELECT COUNT(*) AS artid FROM vbArticles_content WHERE valid='1'");
$totaltuts = number_format($counttutorials['artid']);
Than open your forumhome template and place Total Articles: $totaltuts anywhere you like. :)
Repec
06-15-2003, 02:17 PM
ive installed version 0.2 but when i try and add an article the submit button doesnt work.
You can click it and thats about it, doesnt do anything
Any ideas on how else to improve it ?
If now will push it to v1.0 status and move it to Full Release section and call it a day LOL :D
Kars10
06-15-2003, 02:36 PM
@ cinq, i have made a article counter for each category and also a Hitcounter that displays in the article and the recent articles. If you want i can share this code. :)
Kars
Kars10
06-15-2003, 02:39 PM
Screenshot:
Today at 12:17 AM Repec said this in Post #29 (https://vborg.vbsupport.ru/showthread.php?postid=409239#post409239)
ive installed version 0.2 but when i try and add an article the submit button doesnt work.
You can click it and thats about it, doesnt do anything
Repec , could you check your template vbArticles_addnewarticle.
Better still overwrite it with this one ( same one taken from the template folder in the zip file )
Kars , that would be great :D
Either post here ( or attach the files ) or drop me a Private message , whichever is more convenient for you.
Thanks once again :)
Repec
06-15-2003, 02:51 PM
great it works now :D
Kars10
06-15-2003, 02:54 PM
@ cinq, n/p. I?ll write it - zip it and send it to you. Just pm me your Email-Adress. :)
Kars
gmarik
06-15-2003, 02:58 PM
cinq, you could just make a .zip of that add-on, it would be great, ok?!
gmarik
06-15-2003, 03:00 PM
Today at 07:36 PM Kars10 said this in Post #31 (https://vborg.vbsupport.ru/showthread.php?postid=409244#post409244)
@ cinq, i have made a article counter for each category and also a Hitcounter that displays in the article and the recent articles. If you want i can share this code.
Code, more code, code, code! :classic:
gmarik , will try to get it out as soon as Kars emails me :)
Really appreciate all the help and encouragement I am getting on this hack , this being my first hack and all.
You folks are a great bunch :)
gmarik
06-15-2003, 03:16 PM
Oh, I'll make some template changes and will post them as an add-on, it was a hack everybody has been waiting for a long time.
Repec
06-15-2003, 03:29 PM
i got one comment though, when you submit an article the redirect page flashes by, u cant even read what it says.
Is there a way to make it go slower so that you can what it says?
And maybe another suggestion, can you make it so that a user can edit his or her article after it has been validated?
Kars10
06-15-2003, 03:32 PM
@ cinq, you have email. :)
@ repec, open template vbArticles_doneaddarticle and serach for <meta http-equiv="Refresh" content="0; URL=articles.php?action=main"> replace it with <meta http-equiv="Refresh" content="2; URL=articles.php?action=main">
Gone through it briefly.
Looking good on localhost :D
I dun think I will package this as an add-on , but rather , to merge it to be part of the hack. Seems logical some might want hits counter for their articles/tutorials etc.
Will go thru it in depth and make the neccessary changes and push out the next beta version with hit counters hopefully by tmr.
Thanks Kars :D
UPDATES
version 0.3 is out
- Now displays total number of articles in each category on Articles Home
- Now counts article hits ( views )
- Similiar navigation style ( as forum )
Re-download the attached zip package and read the upgrade txt file carefully if upgrading. Instructions on how to upgrade from both version 0.1 and 0.2 are included.
For fresh installation , pls read the readme txt file contained in the zip package
kaotic
06-16-2003, 02:09 PM
Yet another update! Good news! I always like new features. :D Thanks, cing.
Edit: Got a question. What exactly does your install file do? I need to know the querries. In order to do what I'm trying to do (install the same hack for different sections of the same site in one database), I'll need to change the querries some. :)
kaotic , drop me a PM with your queries , hope not to deviate in this thread with other instructions that might confuse others :)
Btw , Kars and myself are already working on the next version which should incoporate some form of reviewing and commenting system.
We will try to push it out soon :)
kaotic
06-16-2003, 03:21 PM
A commenting system too? Exceptional. :)
Btw, I sent you a PM.
gmarik
06-16-2003, 03:40 PM
cinq, you're programming really fast
/me say THANKS!
swanienufan
06-17-2003, 01:25 AM
I think this is a great hack for my website, but I was wondering if I was missing something.
How can I place a link inside my article. I have tried both vb code and html and everything just prints out as text. Any ideas??
G
Dun use vbCode , thats not supported here.
HTML should work.
<a href="http://www.url.com">URL name</a>
It works for me :)
swanienufan
06-18-2003, 02:34 AM
OK, I'm a bone head, I got it to work. Guess I will be taking HTML 101 again. :banana:
gmarik
06-18-2003, 05:19 AM
Oh, cinq, maybe you should
remake that xHTML? And use
CSS all around?! I'm going on
holidays and won't be able to help
bu when I'll be back in August, I'll
see what I can do. There was a hack:
browse threads by months - that would
be a great integration with an article hack
like yours, do are agree? This is top 5 hack!
PixelFx
06-18-2003, 07:02 PM
I can help with xhtml if needed...
awesome hack :)
Yesterday at 03:19 PM gmarik said this in Post #54 (https://vborg.vbsupport.ru/showthread.php?postid=410175#post410175)
Oh, cinq, maybe you should
remake that xHTML? And use
CSS all around?! I'm going on
holidays and won't be able to help
bu when I'll be back in August, I'll
see what I can do. There was a hack:
browse threads by months - that would
be a great integration with an article hack
like yours, do are agree? This is top 5 hack!
gmarik , sorry but am none too familiar with xHTML .
Have checked up the term and read thru w3.org but i still dun quite get it.
How does the language and usage actually differ from HTML ?
Some links would be good.
As for css , you could just place a css file in your directory and when writing your articles in HTML , just include the style tags to call your css file for displaying your content :)
Browse threads by months .... how would that be a good integration for this hack ? I dun really understand this bit
Today at 05:02 AM PixelFx said this in Post #55 (https://vborg.vbsupport.ru/showthread.php?postid=410460#post410460)
I can help with xhtml if needed...
awesome hack :)
Thanks for the offer PixelFX , will contact u if i need the help :)
gmarik
06-19-2003, 09:01 AM
Browse by months could be very usefull, if builing a site, that does not looks like an ordinary vB board. I've been waiting for years, but I'm a bad php pgrogrammer, there must be a way to integrate it with teh calendar maby. Something we need is used in "blogs".
gmarik , i still do not understand the purpose that would serve in vbArticles , care to elaborate further ?
Thanks for your invaluable feedback thus far :)
gmarik
06-20-2003, 07:47 AM
Cinq - it's elementary, Watson!
Articles (in small companys) are published once a week and If I want to know what happened in August 2002, I just hit the button, not searching it all over, now got the point?
Kinda customized to a specific need , think would leave out that feature.
Right now I am concentrating on the following extra features :
In no particular order :
1) Category View multiple pages
2) Comment on article
3) Rate article
4) Ability to create , edit and delete subcategories
5) Search
6) Category headings , like in the forums.
Probably not that soon though ... lets see what turns up as we go along.
Kars10 is also helping me :)
SuperG
06-24-2003, 12:55 AM
uploading and displaying images within the article...when you upload, it generates a thumnail and displays it at predefined areas in the article, rotating between align left and align right. When you click the thumnail, opens full size image in few window. DAT would be perfect ;-)
That would be way too complicated
I much prefer to design my article layout using HTML myself :)
gmarik
06-24-2003, 11:03 AM
06-22-03 at 07:30 PM cinq said this in Post #61 (https://vborg.vbsupport.ru/showthread.php?postid=411620#post411620)
1) Category View multiple pages
2) Comment on article
3) Rate article
4) Ability to create , edit and delete subcategories
5) Search
6) Category headings , like in the forums.
Wow is the only thing I can say. Have you thought about subcotagerys to make at is in the planned Link System 3.0? Because there where some coders who have allready partly solved this problem, maybe you could just unite? Just to make it less painfull and give it more power, get what I mean?! :smoke:
Will await Keptic's hack then.
TheComputerGuy
06-25-2003, 12:07 PM
Just upgraded to version .03
Very nice, looks like it cleaned up really well, can't wait to see the new version you guys come up with.
06-22-03 at 04:30 PM cinq said this in Post #61 (https://vborg.vbsupport.ru/showthread.php?postid=411620#post411620)
Kinda customized to a specific need , think would leave out that feature.
Right now I am concentrating on the following extra features :
In no particular order :
1) Category View multiple pages
2) Comment on article
3) Rate article
4) Ability to create , edit and delete subcategories
5) Search
6) Category headings , like in the forums.
Probably not that soon though ... lets see what turns up as we go along.
Kars10 is also helping me :)
GREAT!
I'm waiting for the next relase :)
iggy123
06-26-2003, 07:32 PM
Re-download the attached zip package and read the upgrade txt file carefully if upgrading. Instructions on how to upgrade from both version 0.1 and 0.2 are included.
For fresh installation , pls read the readme txt file contained in the zip package [/B]
I can see no instructions on how to upgrade from 0.1 --- please let me know as i am getting an error when trying to launch the articles.php
Invalid SQL: SELECT COUNT(*) AS artid FROM vbArticles_content WHERE categoryid=1 and valid='1'
mysql error: Unknown column 'valid' in 'where clause'
Its in the upgrade file.
Look closely ...
U get the error because you did run the query stated in the upgrade instructions to move from v0.1 to v0.3 :)
Also please click the install button so you get updated on any new releases or bug fixes.
iggy123
06-27-2003, 07:01 PM
Ok i have installed it and it works fine in a way - i am still having issues that it does show paragraphs- or accept html - do i need to use bbcode?
iggy , i do not quite understand you.
Care to elaborate more on the bit about showing paragraphs ?
Nope pure html should work, not bbcodes.
Ok would like for those who installed this hack to try this :
Create an article in a category.
Try to make it a reasonably lengthy one with HTML.
Once done , try to edit this article with that of another lengthy one with HTML.
Go view the article. Does it get updated ?
If it does, repeat the above procedure, does it get reupdated when a new article is overwritten again ?
Would appreciate some feed back on this.
iggy123
06-28-2003, 05:59 AM
Today at 02:05 AM cinq said this in Post #72 (https://vborg.vbsupport.ru/showthread.php?postid=413560#post413560)
iggy , i do not quite understand you.
Care to elaborate more on the bit about showing paragraphs ?
Nope pure html should work, not bbcodes.
If you go to my site and check out the articles section you can see what i mean.
http://clanantivirus.com/forums/articles.php?action=viewarticle&artid=7
when i try to edit it via the admin panel i get the following error message
Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /home/unklem/public_html/forums/admin/vbArticlesadmin.php on line 234
So, I dunno - it could be just me LOL
97cobracpe
06-28-2003, 08:25 AM
Yesterday at 08:38 PM cinq said this in Post #73 (https://vborg.vbsupport.ru/showthread.php?postid=413565#post413565)
Ok would like for those who installed this hack to try this :
Create an article in a category.
Try to make it a reasonably lengthy one with HTML.
Once done , try to edit this article with that of another lengthy one with HTML.
Go view the article. Does it get updated ?
If it does, repeat the above procedure, does it get reupdated when a new article is overwritten again ?
Would appreciate some feed back on this.
OK, after messing with it, I have encountered problems with this hack. Depending on the code I put it, it'll either display everything correctly, or just display everything word for word including all the html code. I'm gonna due some further tests and try to find out what works and what doesn't work. I'm using small parts of the code one at a time for testing to find out what parts do and don't work.
My first finding. This hack doesn't like apostrophies ( ' ). Enter text and it'll save and edit correctly. Throw in some apostrophies and you can kissing editing goodbye.
It's really late and I'm tired, so when I wake up tomorrow, I'll test as extensively as possible and report the bugs here.
Take care.
John
AuthorZone.Com
06-28-2003, 09:18 AM
When I bring up the install script in the browser I get:
Parse error: parse error, unexpected T_STRING in /home/authorz/public_html/forums/admin/vbArticles_install.php on line 269
I am using 2.2.8
On another site I just get a white page...
Please help?
Max
AuthorZone.Com
06-28-2003, 09:27 AM
Also, once I get it working, can you tell me if I can make it so only users I adfd to a certain group can post articles?
I plan to use it for a book review site and I will add users to a Reviewer's group and only they should be able to post in it and the admins...
Can you tell me how to do this?
97cobracpe
06-28-2003, 01:09 PM
Parse error: parse error, unexpected T_STRING in /home/authorz/public_html/forums/admin/vbArticles_install.php on line 269
At first, I got this error too. I found 2 typo's in the vbArticles_install.php file. On line 269 and 291 there is no \ in front of an '.
Here's is the fixed version.
cinq, you should update your first post with this updated installer script I attached. The one in the download does not work.
97cobracpe
06-28-2003, 03:15 PM
OK, I found the bug with the ' problem. There was also a big problem with some html code when adding a new article, and when editing.
When adding new, I would not pass some of the html code, and when editing, it would not update. This only happened when using certain html code.
Two php commands:
addslashes() and htmlspecialchars() were not used correctly with the intent of this hack. I noticed the same thing in the vbLink hack as well (which this was based off of).
cinq,
I have corrected the html code issue as far as I know (This hack is working for me curently without flaws. Also, being able to post html code of user forms is a big security risk. I would suggest that everyone either turn on validation (so you can check the code before approving it), although I think it's safe this way, I'm not positive or to disable user submitions all together. I'm disabling it on my site all together. I'd rather have users email me an html file (that I can check locally) before posting it on my site for security reasons.
Not trying to step on any toes or anything, but I like this hack, and want to use it as quickly as possible, so I figured I help you out by posting my findings.
I'm attaching an updated vbArticlesadmin.php below.
AuthorZone.Com
06-28-2003, 08:59 PM
THANK YOU SOOOOOOOOO MUCH!
I am going to try it now.
I plan to use it for a book review site and I will add users to a Reviewer's group and only they should be able to post in it and the admins...
Can you tell me how to do this?
Max
AuthorZone.Com
06-28-2003, 10:24 PM
Also, can you fix it so READERS can rate the articles/reviews please?
BTW, how do I add icons?
97cobracpe
06-29-2003, 12:33 AM
Today at 04:59 PM AuthorZone.Com said this in Post #80 (https://vborg.vbsupport.ru/showthread.php?postid=413747#post413747)
THANK YOU SOOOOOOOOO MUCH!
I am going to try it now.
I plan to use it for a book review site and I will add users to a Reviewer's group and only they should be able to post in it and the admins...
Can you tell me how to do this?
Max
I noticed you asked the same thing in the links directory thread. This hack was based on it, so the code is pretty much the same. Here is the snippet of code to search for:
// #################### Add Article ####################
if ($action=="addarticle") {
if ($bbuserinfo[usergroupid]=="1" or $bbuserinfo[usergroupid]=="3" or $bbuserinfo[usergroupid]=="4" or $bbuserinfo[usergroupid]=="0") {
eval("dooutput(\"".gettemplate('vbArticles_error1')."\");");
}else{
Follow the same concept I posted in the links directory thread on how to exclude usergroups.
I'm not a coding expert, but adding ratings to this hack seems like it would be rather difficult. Maybe someone more experienced will be able to help you out. For the time being, I'll look into it, as that seems like a cool feature.
AuthorZone.Com
06-29-2003, 01:31 AM
How does the Validate Articles/Links system work?
How do I know when I have to validate them?
How do I know when there are new articles/links submitted?
Thanks
Max
Yesterday at 11:09 PM 97cobracpe said this in Post #78 (https://vborg.vbsupport.ru/showthread.php?postid=413685#post413685)
At first, I got this error too. I found 2 typo's in the vbArticles_install.php file. On line 269 and 291 there is no \ in front of an '.
Thanks 97cobracpe, have updated the download.
Today at 01:15 AM 97cobracpe said this in Post #79 (https://vborg.vbsupport.ru/showthread.php?postid=413698#post413698)
Two php commands:
addslashes() and htmlspecialchars() were not used correctly with the intent of this hack. I noticed the same thing in the vbLink hack as well (which this was based off of).
I figured I help you out by posting my findings.
97cobracpe, thanks once again :)
Dont worry about stepping on my toes or anything, in fact I feel glad that some of you have stepped forward to help me along. I am very new to php and vb in general, nosedived into this hack purely cos i need something on this on my site and could not find any avail here yet.
For myself I too have removed all user submission code in my own installation at my site.
I prefer to have my own editorial team send me the stuff and i will load it up via admincp myself.
But personal preference I guess, at least this hack allows for more flexibility for those who prefer automated user submissions ( and via validation process )
Today at 08:24 AM AuthorZone.Com said this in Post #81 (https://vborg.vbsupport.ru/showthread.php?postid=413769#post413769)
Also, can you fix it so READERS can rate the articles/reviews please?
Kars10 is working on the ratings bit. Got to wait out for it in future versions.
Today at 11:31 AM AuthorZone.Com said this in Post #83 (https://vborg.vbsupport.ru/showthread.php?postid=413796#post413796)
How does the Validate Articles/Links system work?
How do I know when I have to validate them?
How do I know when there are new articles/links submitted?
You either enable or disable this option in your AdminCP under vbulletin options.
When a user submits an article, if enabled, will require your validation b4 it is displayed in your articles section.
To validate, click on the 'Validate new articles' link in your admin cp.
You have to check regularly if you have enabled the validation option as currently the hack does not inform you of any new user submissions.
If any one can help do an add-on to the existing code such that it will email admin ( like notification ) on any new user submissions, i will be most grateful.
Braindg
06-29-2003, 12:16 PM
how would one go about adding permissions to this? as per normal forums? i would like to deny non-members to the articles section..
AuthorZone.Com
06-29-2003, 12:51 PM
PROBLEM!
Ok I tried to validate 3 articles and it sent the server into a tail spin.
The server load overloaded and it will not come down....
Me thinks this hack need alot of fixing... :(
Braindg, here's what you can do:
In articles.php :
Find
if ($action=="viewarticle") {
After that, add the following
if ($bbuserinfo[usergroupid]=="1" or $bbuserinfo[usergroupid]=="3" or $bbuserinfo[usergroupid]=="4" or $bbuserinfo[usergroupid]=="0") {
eval("dooutput(\"".gettemplate('vbArticles_error3')."\");");
}else{
In the same articles.php file , Find
eval("dooutput(\"".gettemplate('vbArticles_articleview')."\");");
After that, add the following
}
Next, add the following attached template.
All done, viewing of articles is now nonviewable by those awaiting confirmation, Coppa users and Unregistered/Not logged in users.
( those usergroup ids - 1 , 3 , 4 )
If you wish to add more usergroups to deny them viewing of articles, simply add in their usergroup ids accordingly.
Yesterday at 10:51 PM AuthorZone.Com said this in Post #88 (https://vborg.vbsupport.ru/showthread.php?postid=413881#post413881)
Ok I tried to validate 3 articles and it sent the server into a tail spin.
The server load overloaded and it will not come down....
Me thinks this hack need alot of fixing... :(
Me thinks it may not be the hack as I cannot replicate this error.
Anyone else facing this problem ?
AuthorZone.Com
06-30-2003, 04:25 AM
<a href="http://www.authorzone.com/forums/articles.php?action=viewcat&catid=8" target="_blank">http://www.authorzone.com/forums/art...iewcat&catid=8</a>
It does not maintain line returns.
Can you help fix this?
Thanks
Max
AuthorZone.Com
06-30-2003, 04:34 AM
also the tables/cells on the main page are HUGE?
How do I fix them so they are as small as possible HIGHT wise?
http://www.authorzone.com/forums/articles.php
Thanks!
Max
AuthorZone.Com
06-30-2003, 04:36 AM
One more thing...
How do I make it so it does not show the ENTIRE articles on the main page in the recent articles section and to make it show just the title linked...
http://www.authorzone.com/forums/articles.php
Thanks!
Max
Braindg
06-30-2003, 04:47 AM
thanks cinq !! worked a treat..
Also, ive not been able to replicate the error by AuthorZone.Com been runnign smooth here..
AuthorZone.Com, perhaps just edit it all in html? its what ive been doing works fine..
AuthorZone.Com
06-30-2003, 04:52 AM
edit what in HTML? I am not good with HTML :(
AuthorZone.Com, like what Braindg mentioned, use HTML.
Otherwise it just outputs text.Using <br> tag should give it line breaks.
Tables and cells, up to you , simply edit the templates to suit the look you want.
The recentbit template only shows the byline ( ie. a short description of the article ).
Unless you editted the hack a bit, it should only show the byline.
Unless you put all that content into the byline field....
:D
Braindg - glad it works for you :D
Do click the install button so you get updated should any new version be released anytime :)
Braindg
06-30-2003, 04:54 AM
your text/content... why not use something like dreamweaver to edit it then?
Braindg
06-30-2003, 04:55 AM
Braindg - glad it works for you :D
Do click the install button so you get updated should any new version be released anytime :) [/B]
ehehe.. oops :D done
There are a few easy to use commerical products like Dreamweaver and Frontpage to play around with WYSIWYG html authoring.
Might wish to try those.
But those are commercial products.
If you are looking for a free one , try this (http://www.evrsoft.com/1stpage/)
Smoothie
06-30-2003, 05:21 AM
cing-
this looks quite good, any idea when it will come out of beta?
Smoothie, actually the main reason its in beta right now is due to the planned addition of more features into this hack.
With some of the corrections provided by fellow members, i believe its basically a-ok.
Otherwise, if you are looking for a basic hack that can be used as a form of reviews, FAQ , tutorial, article ,interviews etc section, it can already be used.
In fact i am using this on my live site too, features planned for further versions of this hack i personally will not be needing but will be including for the benefit of those who may need it/them.
AuthorZone.Com
06-30-2003, 12:24 PM
I got this error: Warning: htmlspecialchars() expects parameter 1 to be string, array given in /home/authorz/public_html/forums/articles.php on line 141
It does not maintain line returns...
Also, see what happens when you try to submit a review please?
I realli need to get this one working right... :(:(:(
"maintains line returns"
now what exactly do you mean ?
I cannot submit an article cos you didnt provide a test account for me to log in :p
Did you change any of the code yourself ?
just an update, managed to get the pagination for articles working ... woot :D
Allows for splitting of articles up into several pages as desired by the article submitter based on a delimiter string.
AuthorZone.Com
07-02-2003, 02:09 AM
Nope, this one is not for me. It need heavy work...
While I cannot ascertain the hack is perfect and bug free , I am consistently looking out for anything that needs correction and with the kind help from others who posted in this thread, just found some and corrected them with their help.
If you found any , it would be great to discuss in further detail so that the hack can be improved on.
If you arent going to even elaborate on your problem , how would you expect others to help you figure things out .. .. ..
AuthorZone.Com
07-02-2003, 02:32 AM
Well, I did elaborate and the response I got was "use html"!
If that is the case, I can just do static pages and screw the hack.
If you want to do a hack, do it right. I rather pay for it if it is well done.
Your hack was so screwed up I just gave up on it seeing how you responded with "use html".
1. The cells between the Category and the link under it which says Submit new review is way too much
here take a look:
http://www.authorzone.com/forums/articles.php
2. The script does not maintain line returns and centers all the text and screws it up. It make all the tex piled up on top.
3. The authenticate feature, it should show a PREVIEW with a submit button instead of the whole article in an imput box.
4. When you pull up articles to authenticate them the Author gets deleted automatically before the page even loads, which makes it impossible to know who the hell posted what.
5. It should automatically link the name of the person/Author who posted an article/review to their profile.
6. There needs to be a preview option for the member who submits it to see what it looks like...
7. The vB has a thread rating system. You can intergrate that code so each article can be rated.
8. The category column is too wide and text too big.
9. The the admin should have the option to show only the article title linked to the article on the index page without the summary.
10. There needs to be an editor like the one in vB or better.
11. The ability to choose text and background colors for the article page and should be able to preset them from admin.
12. vB Code are essential.
13. Number of viewers who read it...
I could think of a bunch more features but these are essential, IMHO.
I hope this helps.
Max
AuthorZone.Com
07-02-2003, 02:33 AM
I have many reviewers and they are not technical, so I need a descent hack. I'll send you some money just do it right please.
cnczone
07-02-2003, 12:09 PM
When someone fills out all the info (author, date, etc..) than I go to valadite it all the fields are filled with dates not the authors name or the title etc what gives???? Now when I', in the CP panel and correct it it's fine.
cnczone
07-02-2003, 05:18 PM
This hack could be great, it needs allot of work PLEASE someone help!!!!
AuthorZone.Com
07-03-2003, 12:39 AM
<a href="http://www.authorzone.com/forums/articles.php?action=viewarticle&artid=4" target="_blank">http://www.authorzone.com/forums/art...rticle&artid=4</a>
That is how the articles look like...
Nasty in my opinion.
97cobracpe
07-03-2003, 08:03 AM
Hmm. Check this out.
http://www.chicagotalk.net/forums/articles.php?action=viewarticle&artid=4
Works for me. The key is to write out the content (how you want the article to look) in html format. That's what I did, using frontpage. I wrote up the article in html, then I copied and pasted the code into the article content field. Simply typing it out won't cut the mustard. It will not automatically format the article the same way you typed it into the field.
While I only have 1 article so far, this is how it looks for me so far.
http://www.chicagotalk.net/forums/articles.php
AuthorZone.Com
07-03-2003, 09:25 AM
The key is that this hack needs a great deal of work.
You can't expect me to teach all my reviewers HTML and how to use Front Page!!!!!
Maintaining line returns should be written into the hack, period!
97cobracpe
07-03-2003, 08:41 PM
Your right, it should. But this hack was designed using the link directory hack as a model. With the other hack, there is no need to have auto formatting built into it as everything is one line big. Maybe in the future someone will do more with this hack, but until then this is the way it is. I personally don't mind it. I'd take a stab at it, but I'm no expert at php.
kaotic
07-05-2003, 10:29 PM
I think I know someone that needs to count their blessings instead of bashing them. :rolleyes:
TheComputerGuy
07-06-2003, 01:05 PM
I can't wait until more releases of this hack...Heck I love it the way it is now, so I know I will later on!
proxyMX
07-09-2003, 05:24 PM
link to download is dead
Its only dead cos i took it out.
limey
07-10-2003, 03:27 AM
ah man right when I was about to try it out. You must've just took it off?! Like seconds before me.
07-02-03 at 12:32 PM AuthorZone.Com said this in Post #107 (https://vborg.vbsupport.ru/showthread.php?postid=414606#post414606)
..If that is the case, I can just do static pages and screw the hack. If you want to do a hack, do it right...
Your hack was so screwed up I just gave up on it ..
07-02-03 at 12:33 PM AuthorZone.Com said this in Post #108 (https://vborg.vbsupport.ru/showthread.php?postid=414607#post414607)
I have many reviewers and they are not technical, so I need a descent hack.
07-03-03 at 10:39 AM AuthorZone.Com said this in Post #111 (https://vborg.vbsupport.ru/showthread.php?postid=414834#post414834)
...Nasty in my opinion.
Listen, you do not like how it is, do not use it, period.
No need to go about saying the hack is screwed up, not decent and nasty.
Whatever I can incoporate into the hack i will try to, along with some help from the others here.
We do not owe you js, so don't make it sound like we do.
If i knew this was the kind of responses i would be getting, i would never have put the hack up in the first place :(
07-04-03 at 06:41 AM 97cobracpe said this in Post #114 (https://vborg.vbsupport.ru/showthread.php?postid=415099#post415099)
Your right, it should. But this hack was designed using the link directory hack as a model. With the other hack, there is no need to have auto formatting built into it as everything is one line big. Maybe in the future someone will do more with this hack, but until then this is the way it is. I personally don't mind it. I'd take a stab at it, but I'm no expert at php.
Yes and moreover, features were clearly stated on the very first post of what it CAN do. As well as planned features.
Thanks for the help 97cobracpe, if you manage to get the line break thing working, do drop me a pm to discuss , would sure appreciate it :)
07-02-03 at 10:09 PM cnczone said this in Post #109 (https://vborg.vbsupport.ru/showthread.php?postid=414691#post414691)
When someone fills out all the info (author, date, etc..) than I go to valadite it all the fields are filled with dates not the authors name or the title etc what gives???? Now when I', in the CP panel and correct it it's fine.
Does anyone face the same error ?
dontpanic
07-10-2003, 05:45 PM
07-05-03 at 07:29 PM kaotic said this in Post #115 (https://vborg.vbsupport.ru/showthread.php?postid=415573#post415573)
I think I know someone that needs to count their blessings instead of bashing them. :rolleyes:
Right on. I think this a great hack. It's free and it's someone elses hard work. Why be a d1ck about it?
cing keep up the good work! :rambo:
Russ_T
07-10-2003, 09:13 PM
cinq: just ignore them mate, the little whinney +++++es can go write their own mod and put it up if they are so much better.
If you could get the link going again sometime please I'd like to install and see as this is exactly what I need, and I'll add any productive comments/help I can.
Try to ignore the moaners though, these people are ++++ heads and theres not much you can do to stop them.
PurpleCow
07-11-2003, 06:12 AM
cinq :
This sure is such a wonderful hack and great work from your end !
As few others mentioned above, just ignore those who stik their tongue out , just for the heck of it.
Hope the new version1.0 you are working on will be released soon.
Thank you for the hard work
Cheers
dontpanic
07-11-2003, 04:40 PM
Excellent hack first of all!
Found and fixed two small errors in the vbArticlesadmin.php file.
Where you have:
<a href='vbArticlesadmin.php?action=editarticle&catid=$catid&artid=$artid'><b>Edit</b></a><br>
<a href='vbArticlesadmin.php?action=removearticle&catid=$catid&artid=$artid'><b>Remove</b></a></td>";
You need to change it to this:
<a href='vbArticlesadmin.php?action=editarticle&catid=$catid&artid=$articleid'><b>Edit</b></a><br>
<a href='vbArticlesadmin.php?action=removearticle&catid=$catid&artid=$articleid'><b>Remove</b></a></td>";
Thanks again cing for a great hack! Can't wait to see what you have in store for the next version! :D
dontpanic
07-11-2003, 05:05 PM
cing, found another fix that makes it work all but perfectly now I think.
In the vbArticlesadmin.php file, locate:
$DB_site->query("UPDATE vbArticles_content SET valid='$val',title='".addslashes(htmlspecialchars($name[$key]))."',byline='".addslashes(htmlspecialchars($desc[$key]))."',author='".addslashes(htmlspecialchars($name[$key]))."',date='".addslashes(htmlspecialchars($name[$key]))."',content='".addslashes(htmlspecialchars($desc[$key]))."' WHERE artid='$key'");
echo "<p>Validated Article: $key</p>\n";
And replace it with:
$DB_site->query("UPDATE vbArticles_content SET valid='$val',title='".addslashes(htmlspecialchars($title[$key]))."',byline='".addslashes(htmlspecialchars($byline[$key]))."',author='".addslashes(htmlspecialchars($name[$key]))."',date='".addslashes(htmlspecialchars($date[$key]))."',content='".addslashes(htmlspecialchars($desc[$key]))."' WHERE artid='$key'");
echo "<p>Validated Article: $key</p>\n";
Also, locate:
makeinputcode("Title :","name[$link[artid]]",$link[title]);
maketextareacode("Description :","desc[$link[artid]]",$link[byline],4,50);
makeinputcode("Author :","name[$link[artid]]",$link[author]);
makeinputcode("Date :","name[$link[artid]]",$link[date]);
maketextareacode("Content :","desc[$link[artid]]",$link[content],10,50);
makeyesnocode("Validate:","validatelink[$link[artid]]",1);
makeyesnocode("Delete:","deletelink[$link[artid]]",0);
maketableheader(" ","",0);
$done=1;
And replace it with:
makeinputcode("Title :","title[$link[artid]]",$link[title]);
maketextareacode("Description :","byline[$link[artid]]",$link[byline],4,50);
makeinputcode("Author :","name[$link[artid]]",$link[author]);
makeinputcode("Date :","date[$link[artid]]",$link[date]);
maketextareacode("Content :","desc[$link[artid]]",$link[content],10,50);
makeyesnocode("Validate:","validatelink[$link[artid]]",1);
makeyesnocode("Delete:","deletelink[$link[artid]]",0);
maketableheader(" ","",0);
$done=1;
This should fix any errors that people had when trying to validate submissions from the AdminCP.
:banana:
iggy123
07-11-2003, 09:18 PM
excellenmt - this works great now - just have to remember to format them properly LOL
dontpanic
07-11-2003, 09:36 PM
OK, If you make the changes below you will be able to accept and validate HTML from the public submission page...of course you still need to get the material in HTML. :cool:
In articles.php, find:
$result = mysql_query("INSERT INTO vbArticles_content (categoryid, title, byline, author, date, content, valid) VALUES ('$catid', '".addslashes(htmlspecialchars($title))."', '".addslashes(htmlspecialchars($byline))."', '".addslashes(htmlspecialchars($author))."', '$date', '".addslashes(htmlspecialchars($content))."', $vd)");
Replace with:
$result = mysql_query("INSERT INTO vbArticles_content (categoryid, title, byline, author, date, content, valid) VALUES ('$catid', '".addslashes(htmlspecialchars($title))."', '".addslashes(htmlspecialchars($byline))."', '".addslashes(htmlspecialchars($author))."', '$date', '".addslashes($content)."', $vd)");
That fixes it so you can submit in HTML and maintain it while it goes into the database.
Now, in vbArticlesadmin.php, find in the DO VALIDATE NEW LINKS section:
$DB_site->query("UPDATE vbArticles_content SET valid='$val',title='".addslashes(htmlspecialchars($name[$key]))."',byline='".addslashes(htmlspecialchars($desc[$key]))."',author='".addslashes(htmlspecialchars($name[$key]))."',date='".addslashes(htmlspecialchars($name[$key]))."',content='".addslashes(htmlspecialchars($desc[$key]))."' WHERE artid='$key'");
And replace it with:
$DB_site->query("UPDATE vbArticles_content SET valid='$val',title='".addslashes(htmlspecialchars($title[$key]))."',byline='".addslashes(htmlspecialchars($byline[$key]))."',author='".addslashes(htmlspecialchars($name[$key]))."',date='".addslashes(htmlspecialchars($date[$key]))."',content='".addslashes($desc[$key])."' WHERE artid='$key'");
No guarantees this will work for you, but I've got it working now that users can submit articles properly formatted in HTML. I can then validate them and they will post formatted in HTML. :rambo:
Updated the hack with fixes from post 126 and 127.
Thanks a million, dontpanic for pointing them out and providing the fixes :)
As for post 128, without the change, your users cannot submit HTML content ?
dontpanic
07-12-2003, 01:27 AM
Today at 10:12 PM cinq said this in Post #130 (https://vborg.vbsupport.ru/showthread.php?postid=417080#post417080)
Updated the hack with fixes from post 126 and 127.
Thanks a million, dontpanic for pointing them out and providing the fixes :)
As for post 128, without the change, your users cannot submit HTML content ?
You mean post 129?
Before that fix, you could submit HTML from the public page (articles.php?action=addarticle) all you wanted...you just lost the formatting when saved. That fix preserves HTML so that when you go to validate it later, its still good.
I have it all tweaked out and running like a champ right now at MCSE World (http://www.mcseworld.com/forums/infocenter.php). I am going to also be integrating an HTML editor into the submission page as well...unforunately that's a commerical product, so I won't be releasing that mod to your hack. :tired:
Thanks again!
Right, will throw that in as well , thanks for the clarification :D
HTML editor ? That sounds interesting, where can more info about it be found ? ( ie. purchased from ? )
You have integrated this hack into your infocenter really nicely.
Will put your site up as another live demo , hope you do not mind :)
Ok updated the hack download.
For those who installed it prior to 12-07-2003 ( today ) , please refer to posts 126, 127, 129 for fixes.
dontpanic
07-12-2003, 02:03 AM
Thanks for all your hard work on this, I couldn't have gotten this far without!
As for adding the site as a live demo, please do...I'll never turn away more traffic. ;)
As for the HTML editor, I'm working with htmlEditbox 2.0 (http://www.labs4.com/htmleditbox/2.0/index.php). Haven't had the chance to start integrating it, but I'll let you know how it goes.
dontpanic
07-12-2003, 02:05 AM
Sorry, just found this one. This affects editing categories from within the CP.
In vbArticlesadmin.php, find:
// ############################# Edit Category #########################
if ($action=="editcat") {
$sql = "SELECT * FROM vbArticles_cat WHERE artcatid=$artcatid";
Replace it with:
// ############################# Edit Category #########################
if ($action=="editcat") {
$sql = "SELECT * FROM vbArticles_cat WHERE artcatid=$catid";
I am really putting this hack through it's paces. Thanks again! :D
I was actually glancing through this hack here (https://vborg.vbsupport.ru/showthread.php?s=&threadid=40283&highlight=eisecure)
Wonder if it can somehow be integrated.
And what does post 135 change ?
dontpanic
07-12-2003, 02:22 AM
Today at 11:10 PM cinq said this in Post #137 (https://vborg.vbsupport.ru/showthread.php?postid=417095#post417095)
And what does post 135 change ?
Sorry, sometimes I forget to explain it all.
If you went to edit a category from within your AdminCP, you would get a fetch error. This corrects that. :)
As for that WYSIWYG editor...dunno, I didn't even see that when I looked earlier...but that's how it always is! If that can be integrated, and it's free, so much the better! :rambo:
Russ_T
07-12-2003, 03:28 PM
cinq - Just to say thanks for giving me the hack and it installed fine.
One little change I made in index.php in /forum/admin I changed
makenavselect("vbArticles","<br>");
for
makenavselect("vbArticles");
as the gap was too big for me.
The edit page also says Byline and not Description :)
I get the error like others when editing and removing wont work for me either?
Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /home/www/zclubnieW/forum/admin/vbArticlesadmin.php on line 234
A couple ideas that might have already been mentioned,
Is it possible to turn on full URL usage for the category image incase we don't want an image from the images folder?
Maybe an e-mail this article to a friend feature one day?
E-mail to the validater saying "New article to validate" with corresponding email option?
Thanks for the hack though, very good stuff, I like! If you would like me to help out or implement something for you just say.
Thanks again! :D I'm a happy bunny now, look at http://www.zclub.net/forum/articles.php?action=viewarticle&artid=2 :D
I'm now busy trying to chase down my vbArticlesadmin.php 234 error :D
Russ_T
07-12-2003, 04:16 PM
Ok found it
in vbArticlesadmin.php
$result = $DB_site->query("SELECT * FROM vbArticles_content WHERE Categoryid=$catid");
if ($myrow = $DB_site->num_rows($result)) {
while ($myrow=$DB_site->fetch_array($result)) {
$hasattach=1;
$articleid=$myrow["artid"];
should be
$result = $DB_site->query("SELECT * FROM vbArticles_content WHERE Categoryid=$catid");
if ($myrow = $DB_site->num_rows($result)) {
while ($myrow=$DB_site->fetch_array($result)) {
$hasattach=1;
$artid=$myrow["artid"];
Last line changes as the $artid reference is used... not $articleid... :D
I haven't checked that fixes it but I'm sure it will.
Cheers
Russ_T
07-12-2003, 05:16 PM
I found a new problem :)
When a user submits from the website and it needs to be validated everything goes fine until the admin validates, when this is done Title and Author get overwritten with the data from Date. I believe it's to do with the line
$DB_site->query("UPDATE vbArticles_content SET valid='$val',title='".addslashes(htmlspecialchars($name[$key]))."',byline='".addslashes(htmlspecialchars($desc[$key]))."',author='".addslashes(htmlspecialchars($name[$key]))."',date='".addslashes(htmlspecialchars($name[$key]))."',content='".addslashes(htmlspecialchars($desc[$key]))."' WHERE artid='$key'");
from line 190 vbArticlesAdmin.php where a lot of things have author=...$name, date=...$name, title=...$name. There seems to be a mix up with $name[$key] holding the date and being used in too many places.
I could be wrong as I haven't looked into it much.
Thanks
PurpleCow
07-13-2003, 05:34 AM
I have a suggestion for the coming up version :
Right now the hack has an option of making the articles viewable only for registered members.
How about giving an option to admin....using which...individual permission can be given for viewable by registered members only.
What i mean, it should be possible to make certain articles viewable by all ( members/guests and other ), while certain articles will be viewable by only Registered members after logging in.
Within a category, few articles can be viewable by all, while others will be viewable by only registered members.
The articles which are viewable by only registered members will be marked with a small icon indicating the same.
Would u like to introduce this feature cinq ??
Thanks much
cleck673
07-13-2003, 07:00 AM
Is there a way to intergrate this with vbportal where you can include a left column.
cleck673
07-13-2003, 03:36 PM
Refering to the previous question, Does anyone else want to know how to? I am close to getting mine setup right. I figured, rather than being lazy - it is something I was, so I am trying to figure it out on my own. Thanks.
PixelFx
07-13-2003, 09:34 PM
to add to this hack, would it be possible to make it so that articles are only viewable by style, and then by group?
dontpanic
07-17-2003, 12:10 AM
07-12-03 at 02:16 PM Russ_T said this in Post #141 (https://vborg.vbsupport.ru/showthread.php?postid=417256#post417256)
I found a new problem :)
When a user submits from the website and it needs to be validated everything goes fine until the admin validates, when this is done Title and Author get overwritten with the data from Date. I believe it's to do with the line
from line 190 vbArticlesAdmin.php where a lot of things have author=...$name, date=...$name, title=...$name. There seems to be a mix up with $name[$key] holding the date and being used in too many places.
I could be wrong as I haven't looked into it much.
Thanks
Russ_T, make sure you perform the code fixes I posted in these locations:
https://vborg.vbsupport.ru/showthread.php?postid=416989#post416989
https://vborg.vbsupport.ru/showthread.php?postid=417000#post417000
https://vborg.vbsupport.ru/showthread.php?postid=417031#post417031
https://vborg.vbsupport.ru/showthread.php?postid=417093#post417093
I've gotten this hack tweaked out and running great with some additional custom mods of my own over at http://www.mcseworld.com/forums/infocenter.php
Best wishes! :smoke:
cnczone
07-17-2003, 01:35 AM
Looks GREAT can you share!!??
dontpanic
07-17-2003, 01:44 AM
Just make sure you download the updated version of the hack from the first page of this thread. Check the date...it should include all of the fixes identified in posts 126 and on...the only other thing I did was to integrate an HTML editor, but that's a commerical app. Lemme know if you have any other questions. :rambo:
morpheusXIIX
07-17-2003, 05:22 AM
I did a very simple template edit to make it easier for registered users who no nothing about HTML. The mod tells the user how to use the br, p, i, b, and u tags.
Although you could easily modify the hack itself so that BB code would print out html. What I did was.
Open template vbArticles_addnewarticle
find:
<smallfont>Full content of the article</smallfont>
add below it:
<P>
<smallfont>
- Use <br> for line breaks<br>
- Use <p> for double line breaks<br>
- To make text bold, encase it in <b>text</b> <br>
- To make text italic, encase it in <i>text</i> <br>
- To make text underlined, encase it in <u>text</u> <br>
</smallfont>
Do with it what you will.
Falkware
07-18-2003, 04:34 PM
Firstly, thanks for a great hack! Working with this beta to hopefully fill a big void on our site. Thanks for taking the time to supply such a nice and needed addon for vbulletin!
Now, I've been keeping tabs with this thread, applying 'fixes' as they come in. I have all the nice updates provided by dontpanic. Thanks mate.
One problem that keeps persisting is the MySQL error on edit bug. Not been able to find a fix for it, and seems there's no fix to the very problem stated by more than me in this thread :)
The Infamous Error:
Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /path/to/forums/admin/vbArticlesadmin.php on line 236
I get this error when I click "View all articles" then click "Edit" on and article in the list.
When I hope the link I notice it has "&artid=" at the end, but no representation of the article id.
I don't know if this is the problem, but if anyone can solve this MySQL error for me I'd be most grateful.
Thanks again for a great hack! Keep up the good work... (Here's the scary part... I got lots of ideas for this awesome system!! omg!) :bunny: :bunny: :bunny:
dontpanic
07-19-2003, 09:01 PM
Falkware...
I think you just need to make the fix I posted here: https://vborg.vbsupport.ru/showthread.php?postid=416989#post416989
Let me know if that fixes it or not.
:cool:
Falkware
07-21-2003, 01:29 PM
Yeah I actually did install all your excellent fixes and it did solve some issues as reported in this thread. This one however is still lingering though, weird...
Thanks for replying :)
Asterik
07-21-2003, 08:38 PM
Ok, i wanna download this hack but its not lettin me lol can someone send me it? Email: webmaster@plugspark.com AIM: MrPr0Grmer MSN: Graalian_Warrior@MSN.com Yahoo: panzerultima THX! i really need it :)
-God-iZ-iLLa-
07-22-2003, 11:54 AM
i get this error when clicking "view/edit/add article"
Fatal error: Call to undefined function: maketableheaderview() in /home/eternale/public_html/forum/admin/vbArticlesadmin.php on line 11
Anything Im Missing here?
kaotic
07-22-2003, 01:37 PM
Use dontpanic's fixes.
-God-iZ-iLLa-
07-22-2003, 07:38 PM
i did still dont work...can anyone who has it working attach there vbArticlesadmin.php File so i can replace the current one?
cindyd
07-24-2003, 09:05 PM
cinq-very nice hack! *Clicking install.
cindyd
07-24-2003, 09:41 PM
When trying to access my regular forum I am getting this fatal error:
Fatal error: Call to undefined function: adminlog() in /home/glassmav/public_html/forum/index.php on line 7
On line 7 is:
if ($action=="") {
adminlog(); -------> this is line 7
}
Can anyone help me out? My board is unaccessible right now. There wasn't a problem prior to this.
That's weird, because this hack doesnt amend anything in your forum index file at all.
Could it be another hack you just installed ?
cindyd
07-24-2003, 11:42 PM
Everything was working fine until this install. They are telling me at Vbulletin to do this:
Reupload your original vB .php files. Make sure you upload them in ASCII and overwrite the ones on the server.
Good grief.
cindyd
07-25-2003, 12:04 AM
OK, I got it fixed.
cindyd
07-25-2003, 02:25 AM
OK, I went to edit an article and got this error message:
Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /public_html/forum/admin/vbArticlesadmin.php on line 234
I already did the changes the dontpanic had listed on page previous pages.
if ($action=="editarticle") {
$sql = "SELECT * FROM vbArticles_content WHERE artid=$artid";
$result = mysql_query($sql);
$myrow = mysql_fetch_array($result);
$artid=$myrow["artid"];
$title=$myrow["title"];
$byline=$myrow["byline"]; ----> this is line 234
$author=$myrow["author"];
$date=$myrow["date"];
$content=$myrow["content"];
cindyd
07-25-2003, 01:56 PM
Does anyone know how to fix the above error?
cindyd
07-27-2003, 10:58 PM
I really like the idea behind this hack, but I cannot edit or delete anything.
Also, I would like to make this area of my forums accessible to paid members only, how would that be accomplished?
Is this hack still being worked on?
If so, could a link be added in the vew article area, there is no way to get back to the Article home page as it is right now.
cindy, i visited your site and can access the articles section alright.
You have no link in view article to get back to the Main Articles Home page is because you editted your templates to take it out.
Please check the viewarticle template again.
It should have navi at the top just below your vb header.
Also do you mean in your admincp , you are unable to delete and edit articles ? This shouldnt be the case if you installed correctly.
Finally, for your paid members, did you place them in a special usergroup? If so, you can allow viewing access only to them by simple change of code in articles.php ( pretty much similiar to the code changes highlighted previously in this thread )
cindyd
07-28-2003, 03:06 AM
Yesterday at 10:24 PM cinq said this in Post #165 (https://vborg.vbsupport.ru/showthread.php?postid=421127#post421127)
You have no link in view article to get back to the Main Articles Home page is because you editted your templates to take it out.
Please check the viewarticle template again.
It should have navi at the top just below your vb header.
OK, I will recheck that.....I see what I deleted and I would like to put the links at the bottom of the page, like in the Links hack. I guess I can figure that out from the Links hack.
Also do you mean in your admincp , you are unable to delete and edit articles ? This shouldnt be the case if you installed correctly.
Yes, see my error message a couple of posts above. You must have seen all the duplicate articles when you went to the site, I can't edit or delete in the Amin CP.
Finally, for your paid members, did you place them in a special usergroup? If so, you can allow viewing access only to them by simple change of code in articles.php ( pretty much similiar to the code changes highlighted previously in this thread ) [/B]
Yes, I found that earlier tonight, thanks.
So all I need is to get the editing and deleting fixed and I'll be very happy!
Here is the error from when I try to edit or delete:
OK, I went to edit an article and got this error message:
Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /public_html/forum/admin/vbArticlesadmin.php on line 234
I already did the changes the dontpanic had listed on page previous pages.
if ($action=="editarticle") {
$sql = "SELECT * FROM vbArticles_content WHERE artid=$artid";
$result = mysql_query($sql);
$myrow = mysql_fetch_array($result);
$artid=$myrow["artid"];
$title=$myrow["title"];
$byline=$myrow["byline"]; ----> this is line 234
$author=$myrow["author"];
$date=$myrow["date"];
$content=$myrow["content"];
Today at 01:06 PM cindyd said this in Post #166 (https://vborg.vbsupport.ru/showthread.php?postid=421139#post421139)
if ($action=="editarticle") {
$sql = "SELECT * FROM vbArticles_content WHERE artid=$artid";
$result = mysql_query($sql);
$myrow = mysql_fetch_array($result);
$artid=$myrow["artid"];
$title=$myrow["title"];
$byline=$myrow["byline"]; ----> this is line 234
$author=$myrow["author"];
$date=$myrow["date"];
$content=$myrow["content"];
Doesnt look like any error there in line 234. Hmm,deletion never had any problems, while an editting problem/s got nicked previously.
Any others facing the same problem ?
Jus went thru the code, seems in order ( then again, i might be missing something , pretty new to this too )
cindyd
07-28-2003, 06:19 PM
Cinq: I have gone over the installation again and that error remains. When I delete an article, I am told in the CP that it has been successful, but it really doesn't delete anything.
When I try to edit I get that error message and all the input boxes are blank.
Solice
07-29-2003, 01:59 AM
First off, thank you for making this wonderful hack cinq... i was wondering though... is there a way to setup permissions for posting articles? so that I could have some categories for users to post in and others for staff...
Solice, that's currently not planned and may not be too.
Do not have much free time on my hands right now :(
FleaBag
07-30-2003, 12:43 AM
After years of coming to this site I finally enter the Beta forum... To find this baby waiting for me!
Nice work. :D
cindyd
07-30-2003, 06:30 PM
cinq: I would test this for you, but I would have to do it on a live board.
corsacrazy
07-30-2003, 06:53 PM
if this is used for tutorials it wood be a gr8 addition to allow adding of images :D
Today at 04:30 AM cindyd said this in Post #174 (https://vborg.vbsupport.ru/showthread.php?postid=421831#post421831)
cinq: I would test this for you, but I would have to do it on a live board.
That would be great cindy, thank you in advance. :)
It should not affect whatever articles you currently have in place. But do a db backup anyways ( not neccessarily the whole db, just the vbArticles tables - cat and content ).
Do feedback to me if it works.
Btw has your old problem been nicked yet ?
Today at 04:53 AM corsacrazy said this in Post #175 (https://vborg.vbsupport.ru/showthread.php?postid=421839#post421839)
if this is used for tutorials it wood be a gr8 addition to allow adding of images :D
corsacrazy , personally i prefer to allow the user to have the versatility of linking their own images.
So at least you can control the layout of the article view.
The feature i am currently working on is allowing for vbcode for article input ( which i am getting someone to test above ), so a simple vb [img ] will allow linking of images which can either be stored in a directory on your server to your liking or from somewhere on the internet :)
Yesterday at 10:43 AM FleaBag said this in Post #173 (https://vborg.vbsupport.ru/showthread.php?postid=421692#post421692)
After years of coming to this site I finally enter the Beta forum... To find this baby waiting for me!
Nice work. :D
Thanks for the kind comments, FleaBag. :D
Do click the install button to be informed of any new updates to this hack.
Right now i am just taking things slow to add up on the features I had hoped to include, once done i will make it a Full release, of cos first ensuring no more known bugs are experienced.
Once again, thanks so much to all who have already installed and tried this hack and feedback your findings/bugreports and provided fixes , i really appreciate it :D
cindyd
07-31-2003, 12:00 AM
Today at 08:16 PM cinq said this in Post #176 (https://vborg.vbsupport.ru/showthread.php?postid=421895#post421895)
That would be great cindy, thank you in advance. :)
It should not affect whatever articles you currently have in place. But do a db backup anyways ( not neccessarily the whole db, just the vbArticles tables - cat and content ).
Do feedback to me if it works.
Btw has your old problem been nicked yet ?
OK, I don't have anything to lose on this hack right now, since I have to do a lot of deletions, anyway.
I still cannot get past those errors I reported earlier.
I will do this either tonight or tomorrow for sure.
PurpleCow
07-31-2003, 04:31 AM
cinq - I just installed this hacka nd ofcourse clicked on the installed button...!
However, i have a very minor problem...that when i load the page mydomain.com/articles.php , the main page has this list of categories and the next table with Recently Added Articles.
The Recently Added Articles section ( entire table ) is not aligned to the center of the actual width..rather its aligned to the left. Which template do i edit to align the same to center.
Thank you
PurpleCow
07-31-2003, 05:48 AM
cinq - I have just PM-ed you the link to my forums under development.
Thanks
cindyd
07-31-2003, 11:56 PM
cinq: I uploaded the files to test out the code and received this error:
Warning: main(vbCode.php): failed to open stream: No such file or directory in /home/glassmav/public_html/forum/articles.php on line 3
<?
require("./global.php");
require_once "vbCode.php";----->this is line 3
if (!isset($action) or $action=="") {
$action="main";
cindy, try this:
<?
require("./global.php");
require_once "./vbCode.php";
if (!isset($action) or $action=="") {
$action="main";
cindyd
08-01-2003, 01:04 AM
OK, I changed it and now this comes up:
Parse error: parse error in /home/glassmav/public_html/forum/articles.php on line 147
On line 147 is this:
?>
UPDATES
version 0.4 is out
- Now allows for basic VBCODE input in article submission and addition.
- Fixed all reported bugs up to post 183
Re-download the attached zip package and read the upgrade_readme.txt file carefully when upgrading from v0.3.
For fresh installation , pls read the install_readme.txt file contained in the zip package
Sorry for the slow updates, been extremely busy lately and having no access to my own comp doesnt help.
Thanks for being patient :)
FYI list of VBCodes allowed :
xx.com (xx)
xx.com
xx (xx@xx.com)
https://vborg.vbsupport.ru/
:D
TheComputerGuy
08-01-2003, 02:03 PM
Just installed v0.4 Will let you know how it goes as far as people using it!
Thanks a lot!
cindyd
08-01-2003, 03:36 PM
Hi Cinq: I upgraded to the new version and tried to edit/remove some duplicate articles and got this error:
Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /home/glassmav/public_html/forum/admin/vbArticlesadmin.php on line 234
This is line 234: $sql = "SELECT * FROM vbArticles_content WHERE artid=$artid";
**Update: I have everything working now! Super!
cindyd
**Update: I have everything working now! Super!
Thats fantastic :D
gmarik
08-02-2003, 11:09 AM
Getting better and better ...
cindyd
08-02-2003, 08:28 PM
I have a request for the Admin CP, could you make the
"content" box area larger? Being an old curmudgeon, I need a bigger area to see better.
While I am making requests, I would like to have some on the Forum Home Display template that would show recently added articles.
The Article section on my board is by paid membership and I want to "tease" the members......
Thanks
FastAttack
08-02-2003, 10:53 PM
one more request can you make it so that certain mods can access this and add faq and articles to the system? because so far its only restricted to admins.. and I don't want to give my mods access to it.
dontpanic
08-03-2003, 03:26 AM
08-01-03 at 03:11 AM cinq said this in Post #184 (https://vborg.vbsupport.ru/showthread.php?postid=422304#post422304)
UPDATES
version 0.4 is out
- Now allows for basic VBCODE input in article submission and addition.
- Fixed all reported bugs up to post 183
Hiya cing...what's really new over the v0.3 plus the changes we discussed? Any new Admin functionality I need to be aware of...just wondering 'cause I've already taken your great hack and hacked it even more to customize it. I've got the HTML editor integrated now in the submission page as well as a search function...of course, those were both commerical add-ons that I had to buy...but ah well, it works nicely.
Thanks again!
:chinese:
Other than the fixes for the bugs reported previously, no other changes.
Check the changelog, main changes are inclusion of the bug fixes and VBcode integration.
I just found a HTML editor thats free , may try to integrate that at a later date too ! :D
PixelFx
08-04-2003, 08:05 PM
1st page 200 / 2003 is the best free html editor, it's great for editing templates with ultra edit ;)
http://www.ultraedit.com
http://www.evrsoft.com
Yep , i use those 2 utilities myself actually.
However i was refering to a WYSIWYG tool for inputting of articles.
:)
anyways the next version will not be too soon, totally bogged down by work ... argh
supreemball
08-07-2003, 03:06 AM
awesome hack, cinq. i installed v0.4 with minimal trouble (except for the html issue in the content field which i fixed by reading the fixes in this thread).
my suggestions for the next release are a ratings system for each article (as well as a 'sort by top ratings' routine).. also get rid of the 'date' option when submitting articles and just autofill it in with php's date() routine (or whatever its called).
Could you point out which html bits you faced errors with ?
I had assumed i had included all fixes prior to that 0.4 release into the download.
Yes, a ratings system is planned but not so soon.
kars10 is working on that, have yet to hear from him.
As for the date function, yes, i intend to make it a timestamp instead of having to manually fill in the date. Should make sorting easier too.
Holidazed
08-07-2003, 05:32 PM
cinq, this is simply awesome. It installed flawlessly.
Some suggestions I would have are already on your todo list (like sub-categories).
Other suggestions I have are as follows.
1. Don't ask for the date, just take it from the system date.
2. Make the "Content" field look more like the posting field in vBulletin.
3.In addition to allowing for vbCode, also have the vbcode buttons above the "Content" box (like on vBulletin.org).
4. An option in the ACP to allow/disallow vbCode and HTML and have the suggestion #3 above show or don't show based on this setting.
5. Have a "Posted By" field show up when displaying an article and have it put in the username of the person who posted it. Even show the "Posted By" when listing articles. This is useful for when the article author is not the same as the person of posted it.
6. An ACP option to choose who is allowed to post/edit/view articles in each category. This is good if you want users to just post articles to a particular category and then you move them to the appropriate spot later. It is also good if you have a series of articles that you want to be available only to your moderators or admins.
7. An option in the ACP to change the Display Order when viewing the list of articles/categories without having to edit each individual article/category. The same way that the forum listing allows you to change the display order without having to edit each individual forum.
8. And lastly (probably not), Add a "Search" feature or tie the articles into the existing vBulletin search routine.
I want to replace my existing FAQ section (which is currently housed in a forum so it can be searched) with this one because it has so much potential.
Overall, good work tho.
Holidazed
08-07-2003, 07:11 PM
I just noticed that when an article is posted, the font is very small. If anybody else is having this problem, just do the following.
Edit the "vbArticles_articleview" template.
Look for:
<smallfont>$content</smallfont>
and replace it with:
$content
That's it. If you want to add a font tag to it, you can. this way your users can just type in the article and it will display int he font of your choice. Something like this:
<font face="Arial" size="3">$content</font>
Holidazed
08-07-2003, 07:48 PM
For those of you who cannot leave well enuf alone, here is something I changed. I wanted the "Recently Added Articles" section to be listed at the top. Here is how you do that.
Edit the "vbArticles_main" template and look for
<table cellpadding="4" cellspacing="1" border="0" width="100%">
<tr id="cat">
<td align="left" background="https://vborg.vbsupport.ru/images/catbg_ukc.gif" bgcolor="#336D95" background="https://vborg.vbsupport.ru/images/catagory_backing.gif" colspan="2"><normalfont color="#000000"><b>$top5catname</b></normalfont></td>
</tr>
<tr align="center">
<td bgcolor="#1D6AA0" align="left"><smallfont color="#EEEEFF"><b>Title</b></smallfont></td><td width="50" bgcolor="#1D6AA0" align="center"><smallfont color="#EEEEFF"><b>Views</b></smallfont></td>
</tr>
$top5listbit
</table>
Remove it. Now look for
<table cellpadding="0" cellspacing="0" border="0" bgcolor="#0A293E" width="95%" align="center"><tr><td>
Just below that, add
<table cellpadding="4" cellspacing="1" border="0" width="100%"><tr id="cat"><td align="left" bgcolor="#336D95" background="https://vborg.vbsupport.ru/images/catagory_backing.gif" colspan="2"><normalfont color="#000000"><b>$top5catname</b></normalfont></td></tr><tr align="center"><td bgcolor="#1D6AA0" align="left"><smallfont color="#EEEEFF"><b>Title</b></smallfont></td><td width="50" bgcolor="#1D6AA0" align="center"><smallfont color="#EEEEFF"><b>Views</b></smallfont></td></tr>$top5listbit</table>
bitg - Age : 93 ??!! haha :D:D
Will consider your ideas, coding time is limited now so i'll take things slow :)
Glad it works for you ! :D
Holidazed
08-08-2003, 07:38 PM
Strangeness. When I try to add an article to any category from the ACP, it does not add the article at all if there is a ' anywhere in any field. It does not give me any errors, it just does not add it.
Now, this is to be expected since this is tying in a database. If I change all the ' to \' it works. However, after I successfully add the article, if I edit it and remove all the \ from the fields, it accepts it just fine.
Another thing, when I add an article via the ACP, it strips all my html from the article field. Yet when I edit the article, I can add the html back in and it accepts it.
This is not mission critical, but I do have to add each article and then edit each article before it is fit to be viewed.
Ideas?
Anyone facing the same problem ?
Weird but i cannot seem to replicate most of the problems reported on my localhost.
Everything works peachy for me....
Dark_Wizard
08-11-2003, 01:40 PM
Try this fix:
find in vbArticlesadmin.php (around line 229):
'".($class->encode($content))."')
change to this:
'".($class->encode($content))."'
Holidazed
08-11-2003, 01:46 PM
Dark Wizard, what will this change do?
Dark_Wizard
08-11-2003, 01:48 PM
Today at 10:46 AM bitg said this in Post #205 (https://vborg.vbsupport.ru/showthread.php?postid=425173#post425173)
Dark Wizard, what will this change do?
It should fix your problem with the '.
If not I have something else that should work
Holidazed
08-11-2003, 06:05 PM
Oh. Cool. Any ideas about the html problem?
Dark_Wizard
08-11-2003, 06:40 PM
Today at 03:05 PM bitg said this in Post #207 (https://vborg.vbsupport.ru/showthread.php?postid=425223#post425223)
Oh. Cool. Any ideas about the html problem?
I haven't looked at it and I cannot as I am involved with 3 other hacks right now but if cinq doesn't get to it before I'm done then I will look into it for you.
gmarik
08-12-2003, 06:19 AM
Perfect! What's about xHTML?
1) if a mod or admin adds and article no validation needed
2) when I press "Submit new Article" in one of the Categorys, for example a category called "Rock Music", it would be good that in the field "Choose category Bellow" would be selected on "Rock Music" (this code could be taken from add a new sub-forum form cp)
4) date could automaticly added, if user does not selects to add his own date
5) Photos could be adde in certain places and text woul go along them :ninja:
6.1) How it is going on with sub-categorys? :surprised:
Dolby
08-13-2003, 10:55 PM
any way to get this to use vbulletins vbcodes instead of using vbcodes.php ?
Also it seems if I use html in the content area it just removes it all together. HTML / XML in the descriptoin works correctly and just displays the code. Many of the tutorials I have will have XML and HTML code for readers to see and try. I figure if it just used vbulletins system it would display correctly.
dontpanic
08-15-2003, 09:53 PM
Hey cing...feature request here! :chinese:
Would it be possible for you to add to the code during the validation process that wrote data to one more row in the vBarticles_content table?
Specially, I have added a field called "url" that is used by my search engine that contains the URL of the article. In my case, that would be something like http://www.mcseworld.com/forums/infocenter.php?action=viewarticle&artid=19 for example.
Obviously the script knows the article number...or least the DB helps it by autoentering this value, so I am asking would it be possible to have the correct URL for the article written into the table during the validation process?
Make sense?
:beard:
Dolby
08-18-2003, 10:41 PM
Ok figured out how to make it use vbulletins vbcode. Also added a field authorid (so i can add an edit feature). author, authorid and date are all automaticly entered.
I'll post the changes I made for myself here after I'm done and its ok with the orignal author.
memobug
08-20-2003, 05:48 AM
This looks very interesting. I've reviewed the screencaps and have a few questions. I am currently using another content management system with my forum that is not integrated in any way into vB other than appearing on my homepage. Here are some of the features I use there and a couple others that I would want to see in something that was vB friendly:
1) Is it possible to move an article from one category to another?
2) When a user performs a search, will it search the articles?
3) How about designating, or attaching a thumbnail image to serve as the article lead-in on the homepage
4) Order articles for display (arbitrary, chronologically or reverse chrono)
5) Designate whether an article or an entire category is visible (5a and perhaps even by user group)
6) Copy an entire article or category (this is very helpful for using articles or cats as templates for future articles, or perhaps archiving old ones.
7) Is it possible to select that a lead-in will link to an off-site article directly (by URL)
8) email article to a friend links
9) article stats (views, mostly)
10 XML RSS Feed output (well we can dream, can't we)
Summary
2, 5a would make it a nice integration to vB. Something I can't do now with stand alone software
1,3,4,5,6,7 are very typical and mostly essential features for publishing environments. If it did not have these features it would be of limited use to me, but I can expect it might serve others well.
8,9, 10 are nice-to-haves
Thanks,
Matt
ITPMenace
08-27-2003, 04:22 AM
Maybe I missed it somewhere, but has anyone found a limit to the number of characters that can be submitted in an article? I have an article in one of my forums that I'm trying to move into the "Articles" section as a test and it won't even show up in "Validate" unless I cut it down to less than 1/4 of it's original size???
FleaBag
08-28-2003, 04:54 PM
Am I the only one who's articles go missing if you use an apostraphe in them?
lasto
08-28-2003, 08:07 PM
LOL no u aint
also try doing one with cut and paste - it dont add em
is some weird stuff in this program
ITPMenace
08-28-2003, 11:23 PM
Today at 03:07 PM lasto said this in Post #216 (https://vborg.vbsupport.ru/showthread.php?postid=429284#post429284)
LOL no u aint
also try doing one with cut and paste - it dont add em
is some weird stuff in this program
Maybe this is my problem. When I copy/paste a large article, it never shows up. If I cut the length down, and then copy/paste it, it shows up. All of the tests I've done where I actually typed the content showed up as well...but none as long as the one I want to copy?????
I hope there's a fix for this...I really don't want to have to retype this article!
Dennis
lasto
08-28-2003, 11:25 PM
yeah is pain aint it
I suzzed this out straight away as im very lazy u see and i love my cut and paste so away i went pasted it all in and nothing showed so i did a simple one and it appeared straight away.
ITPMenace
08-28-2003, 11:32 PM
I'm nowhere near capable enough to figure this one out...hopefully someone will have an idea???
ITPMenace
08-28-2003, 11:38 PM
How hard would it be to make the "Submit New Article" link appear to ONLY the Administrator or Moderators?
ITPMenace
08-28-2003, 11:55 PM
Interesting...I just posted an article with 1 word in the "content". Then, in the "Validate" box, I pasted in the actual text I wanted (complete with basic vBCode formatting). It accepted the text, but hosed the format. Check it out here:
http://forums.itpdiesel.com/articles.php3?action=viewarticle&artid=5
lasto
08-29-2003, 12:17 AM
LOL is well weird that
is one way of getting your text in though m8
ITPMenace
08-29-2003, 12:23 AM
I tested all of the vBCode formatting types I used in that article and they work fine when entered manually. I'm attempting to manually retype this article to see if it will take it with all of the formatting.
For some reason, it's treating "Pasted" text differently than "Typed" text?????
ITPMenace
08-29-2003, 12:51 AM
This is getting more frustrating by the minute. I just completely retyped that article, with all of the formatting, and it still won't appear in "Validate"...$%#* that was a lot of typing!!!
ITPMenace
08-29-2003, 01:29 AM
I just went through and removed ALL of the vBCode formatting and it still won't appear in "Validate"...this still has me wondering if there is a "Message Length" limitation or something that is screwing me up???
obsidian
08-29-2003, 06:22 PM
I think that I am having the same basic problem that you are having. When I go to the vbarticles category page and click submit new article it gives me the box to put in all the info. I put my article in there and click submit and it pops up saying:
The article you submitted will be reviewed and added to the database
Here is where I am a tad confused. It will not show up under the articles list. I am also confused when you guys say it wont appear in validate. Where is this because I have not seen a block or list that shows articles waiting to be validated. I have managed to get a couple other articles in there by putting test in the block and then going into the control panel and clicking edit. I can then paste all of my HTML and it will show up. Part of this might be that I am running VBPortal too. Everything seems to be working for the most part though...just a few hiccups.
ITPMenace
08-29-2003, 07:03 PM
In the Admin Control Panel, you will find a vB Articles section. Here you will find the ability to add/delete articles and categories, and validate and edit articles.
My problem is that these articles are not showing up in the Admin CP???
Dennis
obsidian
08-29-2003, 07:38 PM
Ya I have the VB Ariticles section but I do not have anything to do with validation. I have checked to make sure that the validation is turned on under vBulletin Options too. I have
View/Edit/Add Article
Add Category
View All articles
There is nothing regarding validation under any of those links.
The only way I have been able to get articles in is by going to the admin CP and adding a new article. I fill out all the information and then under the article content block I just put test. I submit it and then go back in and edit that article. I can then paste the HTML into the block and everythign works.
obsidian
08-30-2003, 12:47 PM
Well I fixed the validation block...it shows up in the Admin cp.
I am trying to figure out how to put thumbnail images infront of the reviews. Like the categories currently have. Any tips would be welcome. As it is right now I am going through duplicating the caticon information in a first attempt.
BUZZKILLER
08-31-2003, 07:29 PM
anyone have a working solution to the apostrophe problem?
I tried the one posted previously, and it didn't work.
FleaBag
09-08-2003, 03:41 AM
I imagine it would just involve using Strip Slashes, I'm no guru, but I'll try and look into it tonight if I don't need to sleep for work in the morning.
gmarik
09-09-2003, 04:01 PM
Cinq, tell me how far is it with subcategorys?
Really waiting for the next version and want to help.
SRozhon
09-16-2003, 03:21 PM
Does anyone know how to make the copy/paste work without everything not showing up? I like this a lot if I could copy/paste but I don't have time to re-type everything either. Looks nice though. :)
ITPMenace
09-16-2003, 03:27 PM
I determined that my copy/paste problems were with apostrophes in words like "don't". I had to strip out every apostrophe and it pasted just fine. Hope that helps.
SRozhon
09-16-2003, 05:03 PM
thank you that did help. I must have missed that. Thanks so much for re-posting it for me. :)
SRozhon
09-16-2003, 05:33 PM
Ya I have the VB Ariticles section but I do not have anything to do with validation. I have checked to make sure that the validation is turned on under vBulletin Options too. I have
View/Edit/Add Article
Add Category
View All articles
There is nothing regarding validation under any of those links.
The only way I have been able to get articles in is by going to the admin CP and adding a new article. I fill out all the information and then under the article content block I just put test. I submit it and then go back in and edit that article. I can then paste the HTML into the block and everythign works.
It is in you vbulletin Options (the one on the top of the list of things in admin/index.php) When you click Options it will be at the end of those (after Time/Date Options, etc.) listed.
SRozhon
09-20-2003, 06:44 PM
I don't know why this works but it does.
First go to your admin panel and click to add a new article.
then just put a few letters or something in the article field (no quotes) and submit in normally. This gives it an article number.
Then you just edit the article and put your real content in there including html or whatever. You can have as many quotes as you want. submit the Editted changes.
Click view all articles and walla it is there with no problems (quotes and all).
Goofy, eh? It is working for me though.
sabret00the
09-26-2003, 07:11 PM
this don't work for me, is there any chance of an update coming out soon?
FleaBag
09-26-2003, 07:54 PM
Who knows?!
We wait in hope...
PAINTBALLM
10-07-2003, 03:04 AM
Would it be possible to add a feature to insert images wherever you need them, so an article could turn out like this... http://paintball.com/features/story.cfm?placementid=2389&Clickon=PGG
gmarik
10-07-2003, 09:47 AM
PAINTBALLM,
I could help you. It can be done with BBcode easy.
I've got the codes for my board.
PAINTBALLM
10-07-2003, 09:51 AM
alright, thanks!
MikeeX
10-18-2003, 07:00 AM
Does this work with vB 3 beta 7 ?
gmarik
10-18-2003, 10:44 AM
Ofcourse not with vB3 ... for now.
corsacrazy
10-20-2003, 11:06 PM
any news on 0.5 ?
Ok figured out how to make it use vbulletins vbcode. Also added a field authorid (so i can add an edit feature). author, authorid and date are all automaticly entered.
Dolby, do post the changes you made to enable usage of vB's vbcode. Could save some work on my end.
Thanks
picked up work on this hack again ... keep a lookout for updates on the first page.
corsacrazy
10-23-2003, 07:09 AM
nice work matey hope you hav time to compleate good luck :)
corsacrazy
10-23-2003, 09:56 AM
nice one matey :P
FleaBag
10-23-2003, 01:39 PM
Looking great. Really looking forward to an update. Cinq, if you would consider it, when this hack is completed - I'd be willing to pay for a vB3 conversion. This hack and the Link Database hack is all that's holding me back - not that I mind as all is working well! :)
Thanks again.
vBulletin® v3.8.12 by vBS, Copyright ©2000-2025, vBulletin Solutions Inc.