Hide Tag Special

Started by enik, April 11, 2005, 03:41:07 PM

Previous topic - Next topic

Kindred

Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

abhi

#1701
Please help me to remove this! An updated / changed file can be useful

Error on installation,


Code: (Find) [Select]
static $disabled;


Code: (Add Before) [Select]

// On the first Parsing i will gernerate all things i need ;) after that it's not needable :)
if (!isset($modSettings['hide_preparedOption']))
{
// First there is nothing in it ;)
$modSettings['hide_preparedOption']['hiddentext'] = ' ';
$modSettings['hide_preparedOption']['unhiddentext'] = ' ';

if (empty($modSettings['hide_noinfoforguests']) || !$user_info['is_guest'])
{
// Prepare the hidden information :)
$modSettings['hide_preparedOption']['hiddentext'] = isset($modSettings['hide_hiddentext']) ? $modSettings['hide_hiddentext'] : '';
$modSettings['hide_preparedOption']['hiddentext'] = str_replace('$language', $user_info['language'], $modSettings['hide_preparedOption']['hiddentext']);
if (!empty($modSettings['hide_MUIswitch']) && isset($txt['hide_hiddentext']))
$modSettings['hide_preparedOption']['hiddentext'] = str_replace('$txtvariable', $txt['hide_hiddentext'], $modSettings['hide_preparedOption']['hiddentext']);
if (!empty($modSettings['hide_enableHTML']))
$modSettings['hide_preparedOption']['hiddentext'] = un_htmlspecialchars($modSettings['hide_preparedOption']['hiddentext']);

// Prepare the unhidden infomation?
if (!empty($modSettings['hide_enableUnhiddenText']))
{
$modSettings['hide_preparedOption']['unhiddentext'] = isset($modSettings['hide_unhiddentext']) ? $modSettings['hide_unhiddentext'] : '';
$modSettings['hide_preparedOption']['unhiddentext'] = str_replace('$language', $user_info['language'], $modSettings['hide_preparedOption']['unhiddentext']);
if (!empty($modSettings['hide_MUIswitch']) && isset($txt['hide_unhiddentext']))
$modSettings['hide_preparedOption']['unhiddentext'] = str_replace('$txtvariable', $txt['hide_unhiddentext'], $modSettings['hide_preparedOption']['unhiddentext']);
if (!empty($modSettings['hide_enableHTML']))
$modSettings['hide_preparedOption']['unhiddentext'] = un_htmlspecialchars($modSettings['hide_preparedOption']['unhiddentext']);
}
}

// So prepare the unhidden Option for the Parser ;)
if (!empty($modSettings['hide_useSpanTag']))
{
$modSettings['hide_preparedOption']['before_info'] = '<span class="hiddencontent">';
$modSettings['hide_preparedOption']['after_info'] = '</span>';
}
else
{
$modSettings['hide_preparedOption']['before_info'] = '<div class="hiddencontent">';
$modSettings['hide_preparedOption']['after_info'] = '</div>';
}

// Okay Let's see where i must put the unhidden Informations :)
if (!empty($modSettings['hide_enableUnhiddenText']) && empty($modSettings['hide_onlyonetimeinfo']))
{
if (empty($modSettings['hide_posUnhiddenText']) || $modSettings['hide_posUnhiddenText'] == 4)
$modSettings['hide_preparedOption']['after_info'] .= $modSettings['hide_preparedOption']['unhiddentext'];
elseif ($modSettings['hide_posUnhiddenText'] == 3)
$modSettings['hide_preparedOption']['after_info'] = $modSettings['hide_preparedOption']['unhiddentext'].$modSettings['hide_preparedOption']['after_info'];
elseif ($modSettings['hide_posUnhiddenText'] == 2)
$modSettings['hide_preparedOption']['before_info'] .= $modSettings['hide_preparedOption']['unhiddentext'];
elseif ($modSettings['hide_posUnhiddenText'] == 1)
$modSettings['hide_preparedOption']['before_info'] = $modSettings['hide_preparedOption']['unhiddentext'].$modSettings['hide_preparedOption']['before_info'];
else
$modSettings['hide_preparedOption']['after_info'] .= $modSettings['hide_preparedOption']['unhiddentext'];
}

$modSettings['hide_preparedOption']['parse_content'] = !empty($modSettings['hide_enableUnhiddenText']) && empty($modSettings['hide_onlyonetimeinfo']);

// Okay this is the check up if he is allowed to unhide it everytime! (Risky if wrong setup or diffrent mods can handle hide tag)
$modSettings['hide_preparedOption']['auto_unhide_parser'] = false;
if (!empty($modSettings['hide_unhideparser']) && !empty($modSettings['hide_autounhidegroups']))
{
$modSettings['hide_autounhidegroups'] = !is_array($modSettings['hide_autounhidegroups']) ? explode(',', $modSettings['hide_autounhidegroups']) : $modSettings['hide_autounhidegroups'];
foreach ($user_info['groups'] as $group_id)
if (in_array($group_id, $modSettings['hide_autounhidegroups']))
{
$modSettings['hide_preparedOption']['auto_unhide_parser'] = true;
break; //One is enouph ;D
}
}
}

// Hide Mod.. i remove the code before i do anything...
if ($message !== false && !empty($message))
{
if ($modSettings['hide_preparedOption']['auto_unhide_parser'])
$context['user_post_avaible'] = 1;
// Add the Hidden Text at the end of the post :)
if ((empty($context['user_post_avaible']) || !isset($context['user_post_avaible'])) && !empty($modSettings['hide_onlyonetimeinfo']) && hideTagExists($message, $cache_id))
$message .= '[br]'.$modSettings['hide_preparedOption']['hiddentext'];
// Here i remove this content :) or show onetime unhide info :)
if (!isset($context['user_post_avaible']) || empty($context['user_post_avaible']))
{
// Remove it ;D
$message = preg_replace("/\[hide\](.+?)\[\/hide\]/i", (empty($modSettings['hide_onlyonetimeinfo']) ? $modSettings['hide_preparedOption']['hiddentext'] : "&nbsp"), $message);
$message = preg_replace(array('~\n?\[hide.*?\].+?\[/hide\]\n?~is', '~^\n~', '~\[/hide\]~'), (empty($modSettings['hide_onlyonetimeinfo']) ? $modSettings['hide_preparedOption']['hiddentext'] : "&nbsp"), $message);
}
// Okay i need to add the unhidden information at the end of the post :)
elseif (!empty($context['user_post_avaible']) && !empty($modSettings['hide_onlyonetimeinfo']) && !empty($modSettings['hide_enableUnhiddenText']) && hideTagExists($message, $cache_id))
$message .= '[br]'.$modSettings['hide_preparedOption']['unhiddentext'];
}


GUNS32

Me to, the same error in SMF 2.0.2
can you support us?
Thank you

Yo también, el mismo error en SMF 2.0.2
¿puede darnos soporte?
Gracias

haito

i have a problem, "Unhidden Text Information" cant appear in the post
any sollution?

i use SMF 2.0.2 & hide tag special 3.0
www.japanesia.co.id | Portal Berita & Komunitas Untuk Kamu yang Suka Jepang

lucas-ruroken

Quote from: haito on July 28, 2012, 09:51:26 PM
i have a problem, "Unhidden Text Information" cant appear in the post
any sollution?

i use SMF 2.0.2 & hide tag special 3.0

hi..

the error log say something?

Quote from: GUNS32 on July 14, 2012, 04:10:02 AM
Me to, the same error in SMF 2.0.2
can you support us?
Thank you

Yo también, el mismo error en SMF 2.0.2
¿puede darnos soporte?
Gracias


mmm i don't undestand... do you wanna install or uninstall the mod?

If you wanna install... install it with the error, and attachme the Subs.php
Adk Portal 3.1 is coming....

Design your universe!

haito

Quote from: lucas-ruroken on July 30, 2012, 10:27:36 AM
Quote from: haito on July 28, 2012, 09:51:26 PM
i have a problem, "Unhidden Text Information" cant appear in the post
any sollution?

i use SMF 2.0.2 & hide tag special 3.0

hi..

the error log say something?


nothing strange with error log...
i installed this mod without error
www.japanesia.co.id | Portal Berita & Komunitas Untuk Kamu yang Suka Jepang

Rain Forest

Quote from: lucas-ruroken on July 30, 2012, 10:27:36 AM
Quote from: haito on July 28, 2012, 09:51:26 PM
i have a problem, "Unhidden Text Information" cant appear in the post
any sollution?

i use SMF 2.0.2 & hide tag special 3.0

hi..

the error log say something?


Same problem for me..

Maybe this:

8: Undefined index: online
Apply Filter: Only show the errors from this file
File: /var/www/vhosts/website.../httpdocs/forum/Sources/Load.php
Line: 1283

8: Undefined index: online
Apply Filter: Only show the errors from this file
File: /var/www/vhosts/website.../httpdocs/forum/Sources/Load.php
Line: 1281

8: Undefined index: online
Apply Filter: Only show the errors from this file
File: /var/www/vhosts/website.../httpdocs/forum/Sources/Load.php
Line: 1285


forum: www.bluetender.net

Hide-tag special settings


Kindred

1- your online error is unlikely to be related to the hide tag mod....
2- I suspect that you have a conflicting mod somewhere... probably something that uses javascript, like highslide, aeva, glossary, etc...
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

Rain Forest

Hmm, which one do you think it causes the problem?



Kindred

anything that uses javascript...

enotify probably...
possibly ncode image resizer or SAVE or anything else that uses javascript...
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

Rain Forest

Hmm, I have uninstalled Enotify, Voter Visibility, Ncode, Smart Pagination, SMFPacks Likes Lite Mod and Simple Audio Video Embedder.. Nothing happened..

Bugo

Is there $txt['online'] variable in index.english.php?

Rain Forest

Quote from: Bugo on October 03, 2012, 01:32:01 PM
Is there $txt['online'] variable in index.english.php?

After, this: http://www.simplemachines.org/community/index.php?topic=487602.msg3415313#msg3415313, yes.

Vevery weird.. I mean.. this Hidden Text Information is visible so why not the UnHidden Text Information..

enik

I have watched many bugs on this mod, sorry, we talked adk team members, and we decided that this mod requires a major change, will not be soon, but we promise it will be a great job, much lighter, less editions of code, integrate hooks, and a lighter and powerful js.

Regards enik...

techguy

how to unhide content, when visitor will like us on facebook

Kindred

techguy,

there is no capability in this mod to detect that or do that
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

johnpaul2k2

i saw the sample of this mod and i want to know. is there any way to add facebook button. once you "like us" and probably  refresh, the hidden item will unlock???

Kindred

johnpaul2k2,

did you even bother to READ the question ans answer just above your post?! ??? !!!

Quote from: techguy on November 10, 2012, 07:25:55 AM
how to unhide content, when visitor will like us on facebook
Quote from: Kindred on November 10, 2012, 08:24:12 AM
techguy,

there is no capability in this mod to detect that or do that
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

johnpaul2k2

yea i did.

i thought such has been discussed in the previous pages. sorry about that. but can't it be possible to edit manually ???
some people might not like to register on your forum ,even when you are have facebook login which is even the easiest way to register?

to me, the facebook will be the best option

1. east to click the button
2. spread your post(s) on the social site

so?

Advertisement: