SMF Post Prefix

Started by Diego Andrés, May 09, 2015, 11:42:18 PM

Previous topic - Next topic

0 Members and 2 Guests are viewing this topic.

Diego Andrés

Link to the mod




SMF Post Prefix
Developed by Diego Andrés



Introduction
SMF Post Prefix mod allows you to set prefixes for your topics and easily customize them with colors and icons.

Features
  • Add/Edit prefixes
    • Enable/Disable prefix
      • Enable/Disable prefix
    • Select a color for the prefix
      • Text color
      • Background color
    • Add a class for an icon
    • Select allowed groups to use specific prefix
    • Select boards where the prefix can be used
  • Select boards where the prefix will be required (forced)
  • Permissions
    • Manage prefixes
    • Use prefixes (Global permission)
  • Filter Topics by prefix
    • Enable the filter box on selected boards
  • Display prefixes in the boardindex and latest posts
  • Display prefixes in the unread posts/replies action

Localization
English
Spanish
Russian
Turkish
French


Crowdin
Changelog
GitHub
Last Edit: February 25, 2023, 08:38:09 AM by Diego Andrés

Rockman

Hola buenas,miren uso el SMF Post Prefix y me gustaria cambiar el estilo de de los prefijos como otro foro.

Estilo que quiero poner:



Estilo de mi foro:



Tambien me gustaria que en el post detras de "Probando" me gustaria poner el prefijo tambien,¿como pongo eso tambien?

Gracias.

Diego Andrés

Muy fácil.
Sources/Subs-PostPrefix.php
Code (Buscar) Select
if ($row['bgcolor'] == 1 && !empty($row['color']))
$format .= 'padding: 4px; border-radius: 2px; color: #f5f5f5; background-color: '. $row['color'];


Code (Reemplazar) Select
if ($row['bgcolor'] == 1 && !empty($row['color']))
$format .= 'padding: 2px; font-size: 11px; font-weight:bold; border-bottom: 1px solid rgba(0, 0, 0, 0.3); border-radius: 3px; box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05) inset, 0 1px 0 rgba(255, 255, 255, 0.1); color: #f5f5f5; background-color: '. $row['color'];





Display.template.php
Code (Buscar) Select
<a href="', $message['href'], '" rel="nofollow">', $message['subject'], '</a>

Code (Reemplazar) Select
<a href="', $message['href'], '" rel="nofollow">', !empty($message['counter']) ? $message['subject'] : $context['prefix_subject'], '</a>

Rockman

Quote from: Diego Andrés on June 26, 2015, 06:56:46 PM
Muy fácil.
Sources/Subs-PostPrefix.php
Code (Buscar) Select
if ($row['bgcolor'] == 1 && !empty($row['color']))
$format .= 'padding: 4px; border-radius: 2px; color: #f5f5f5; background-color: '. $row['color'];


Code (Reemplazar) Select
if ($row['bgcolor'] == 1 && !empty($row['color']))
$format .= 'padding: 2px; font-size: 11px; font-weight:bold; border-bottom: 1px solid rgba(0, 0, 0, 0.3); border-radius: 3px; box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05) inset, 0 1px 0 rgba(255, 255, 255, 0.1); color: #f5f5f5; background-color: '. $row['color'];





Display.template.php
Code (Buscar) Select
<a href="', $message['href'], '" rel="nofollow">', $message['subject'], '</a>

Code (Reemplazar) Select
<a href="', $message['href'], '" rel="nofollow">', !empty($message['counter']) ? $message['subject'] : $context['prefix_subject'], '</a>

¡Muchas gracias!,ya lo tengo igual gracias a ti (si,se que eres el creador de la modificacion)

Diego Andrés

Gracias a ti por usar el mod  O:-)
Igual la idea cuando se creó era que se tuviera un mod gratis y que fuera simple y funcional, espero que el tiempo pronto me permita agregarle nuevas funciones y características.
Seguramente incluiré alguna cosilla para darle una personalización extra (de estilo) sin editar los archivos del mod.

En la sig. actualización agregaré la segunda modificación que pediste

Saludos!

Diego Andrés

Mod updated to version 2.0.1  8)
Last Edit: July 15, 2015, 10:31:51 PM by Daniel

Diego Andrés

Mod updated! New version 2.0.2

korl3one

He instalado SMFPostPrefix_forSMF2.0.x_2.0.2 hasta aqui todo bien, el problema surge en el momento de activar el mod en los foros, solo se activa hasta cierta cantidad de foros contando  los foros y sudforos, he visto que al desactivar el mod en un foro de inmediato puedo activarlo en aquel foro que no pudo ser activado, en conclucion tiene un limite de numero de foros al cual se puede activar. Necesito por favor que me ayuden con esto para colocar de forma ilimitada. Le adjunto imagenes. Saludos

korl3one

Solucionado Diego Andres ha actualizado el mod. saludos

adonix

Test failed at ./Sources/Subs-Recent.php
Test failed at ./Sources/MessageIndex.php
Test failed at ./Themes/greeny/Display.template.php ( http://smftricks.com/index.php?topic=850 )

I am using 2.0.11 SMF Version.
Kindly hely to fix the errors.

Diego Andrés

Attach the first two files and I'll modiffy them before you install the mod (this way you won't get errors), the third error is not going to cause any trouble, you can just ignore it.

adonix

Quote from: Diego Andrés on September 24, 2015, 09:27:44 PM
Attach the first two files and I'll modiffy them before you install the mod (this way you won't get errors), the third error is not going to cause any trouble, you can just ignore it.

I am using greeny theme (http://smftricks.com/index.php?action=downloads;sa=view;down=92)
So kindly check display.template file also so that there will be no error in theme for this module.

Regards.

Diego Andrés

Try with the following

And I cannot fix the Display.template because it hasn't the code the mod search, just install it with the error, it will still work.

adonix

Quote from: Diego Andrés on September 27, 2015, 11:01:33 AM
Try with the following

And I cannot fix the Display.template because it hasn't the code the mod search, just install it with the error, it will still work.

Oh thanks Diego,..error gone while installing,..but i am just scared for greeny theme that single error :(
May i know what will it affect ??

Diego Andrés

Nothing, it's supposed to add the prefix to the topic title, but on greeny there isn't.