vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 4.x Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=245)
-   -   New Posting Features - Easy Forms v4.x - Create a form or multiple forms without php or html knowledge (https://vborg.vbsupport.ru/showthread.php?t=234385)

clubvr4 05-25-2011 01:58 PM

Quote:

Originally Posted by clubvr4 (Post 2199743)
I've also tried using the following code, to no avail.

PHP Code:

require_once(DIR '/includes/functions_prefix.php');  
$thisanswer $q[$formbit[id]];  
$forumid $form['forumid'] = XX
$prefix_options fetch_prefix_html($form['forumid'], $thisanswertrue);  
$answer '<select name="' $formbit[id] . '" id="q_' $formbit[id] . '" class="bginput">'
$answer .= '<option value="">'.$vbphrase[no_prefix_meta].'</option>';  
$answer .= $prefix_options;  
$answer .= '</select>'

However,

using the above code, and the no attachments code you kindly provided me before - I find that when i click on attachments i do not have permissions to access to FUM..

PHP Code:

$currentattaches $db->query_first("SELECT COUNT(*) AS countrows FROM " TABLE_PREFIX "attachment WHERE posthash = '" $db->escape_string($posthash) . "' AND userid = " $vbulletin->userinfo['userid'] );
$attachcount $currentattaches['countrows'];
if (!
$attachcount)
{
$complete false;
$customerror .= '<div class="blockrow"><div>Error, No attachments!</div></div>';


Removing either the no attachment code or the prefix select code allows me to once again open FUM.

/facepalm..

found #879

All sorted now...

clubvr4 05-25-2011 06:48 PM

Me again...

Its all working now, so im very happy - But, I am wondering....

I have 5 prefixes configured on the for sale forum, there are 3 forms being used to input threads into this forum. What i would like is that one of these forms, only presents 2 of the 5 prefixes, ensuring that people dont click one of the other 3 by mistake.

Is this possible somehow?

Cheers

helwoe 05-31-2011 01:43 AM

Anyone?

Quote:

Originally Posted by helwoe (Post 2199346)
Is there a way to tweak this code to make multi-select drop down list?

Code:

$answer .= '<select name="'.$formbit[id].'">';
$answer .= '<option></option>';
$thisanswer = $q_{$formbit[id]};
$members = $db->query_read("SELECT * FROM " . TABLE_PREFIX . "user
WHERE membergroupids LIKE \"%17%\"
ORDER BY username ASC");
    while($row = $db->fetch_array($members)) {
$answer .= '<option value="'.$row[username].'"';
if ($row[username] == $thisanswer) {
$answer .= 'selected="selected"';
}
$answer .= '>'.$row[username].'</option>';
}
$answer .= '</select>';



KevinL 06-04-2011 11:50 AM

I have this on a clients site. They have reviews setup in certain forums using this mod.

There is one forum though that the "post new review" button does not work. There is just a '1' after the forum URL. It is set up just like every other form forum.

Is there something I am over looking?

Any help would be great!

Thanks :)

scubasteve3 06-04-2011 06:57 PM

Sorry, I have not been able to read through all 89 pages of this thread. Great mod! I was wondering, is there a way to change the nav link. I want to change the name from the default "Forms". Also, is it possible to make this a button somewhere on the page instead of in the navbar. Thanks!

bananalive 06-05-2011 03:27 PM

Quote:

Originally Posted by scubasteve3 (Post 2203538)
Sorry, I have not been able to read through all 89 pages of this thread. Great mod! I was wondering, is there a way to change the nav link. I want to change the name from the default "Forms". Also, is it possible to make this a button somewhere on the page instead of in the navbar. Thanks!

AdminCP -> Edit Phrase -> forms

There is also a link in navbar under 'Quick Links'

Or post the html link in one of your templates where you want it.

bananalive 06-05-2011 03:29 PM

Quote:

Originally Posted by KevinL (Post 2203380)
I have this on a clients site. They have reviews setup in certain forums using this mod.

There is one forum though that the "post new review" button does not work. There is just a '1' after the forum URL. It is set up just like every other form forum.

Is there something I am over looking?

Any help would be great!

Thanks :)

I'm not sure how you've setup it, but check the html or plugin which edits the url.

bananalive 06-05-2011 03:39 PM

Quote:

Originally Posted by helwoe (Post 2199346)
Is there a way to tweak this code to make multi-select list?

Code:

$answer .= '<select name="'.$formbit[id].'">';
$answer .= '<option></option>';
$thisanswer = $q_{$formbit[id]};
$members = $db->query_read("SELECT * FROM " . TABLE_PREFIX . "user
WHERE membergroupids LIKE \"%17%\"
ORDER BY username ASC");
    while($row = $db->fetch_array($members)) {
$answer .= '<option value="'.$row[username].'"';
if ($row[username] == $thisanswer) {
$answer .= 'selected="selected"';
}
$answer .= '>'.$row[username].'</option>';
}
$answer .= '</select>';



Quote:

Originally Posted by helwoe (Post 2201916)
Anyone?

PHP Code:

$answer .= '<select name="'.$formbit[id].'[]" multiple="multiple" size="4">';
$answer .= '<option></option>';
$thisanswer explode(',',$qo[$formbit[id]]);
$members $db->query_read("SELECT * FROM " TABLE_PREFIX "user
WHERE membergroupids LIKE \"%17%\"
ORDER BY username ASC"
);
    while(
$row $db->fetch_array($members)) {
$answer .= '<option value="'.$row[username].'"';
if (
in_array($row[username], $thisanswer)) {
$answer .= 'selected="selected"';
}
$answer .= '>'.$row[username].'</option>';
}
$answer .= '</select>'


bananalive 06-05-2011 03:41 PM

Quote:

Originally Posted by clubvr4 (Post 2199914)
Me again...

Its all working now, so im very happy - But, I am wondering....

I have 5 prefixes configured on the for sale forum, there are 3 forms being used to input threads into this forum. What i would like is that one of these forms, only presents 2 of the 5 prefixes, ensuring that people dont click one of the other 3 by mistake.

Is this possible somehow?

Cheers

Yes, but you'll have to use the form hooks.

bananalive 06-05-2011 03:42 PM

Quote:

Originally Posted by Evertonized (Post 2199745)
When I submit the form it says thanks for submitting and looks like it's worked. However the results show no one has submitted a form.

What could be the problem?

Have you selected 'Save to Database' as Form Action?


All times are GMT. The time now is 01:35 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.02682 seconds
  • Memory Usage 1,773KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (2)bbcode_code_printable
  • (3)bbcode_php_printable
  • (8)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (5)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete