TP-Docs
HTML5 Icon HTML5 Icon HTML5 Icon
TP on Social Media

Recent

Welcome to TinyPortal. Please login or sign up.

March 29, 2024, 05:49:09 AM

Login with username, password and session length
Members
Stats
  • Total Posts: 195,106
  • Total Topics: 21,213
  • Online today: 358
  • Online ever: 3,540 (September 03, 2022, 01:38:54 AM)
Users Online
  • Users: 1
  • Guests: 327
  • Total: 328
  • @rjen

Probleme permission écriture article

Started by john013, August 23, 2011, 11:18:57 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

john013

Bonjour,
donc je suis sous smf 2.0 tp
j'utilise la création d'article sans probleme , par-contre pour atribuer la fonction écriture a une personne:
-la page d'écriture s'affiche mais sans aucune option,
-une fois le texte écrit il soumet mais il y a une erreur "val" il ne trouve pas dans quel catégorie inséré
et il ne peut choisir la catégorie .
pouvais vous me dire comment réglé le pb merci.
www.ssd-handball.com
smf 2.0
tp 1.104
Trad Fr de Tinyportal v1.0 RC1
theme epic 2.0
mode:  -Add GooglePlus to Posts    1.0    
-FB & Twitter Sharer Mod 2.0    2.0    
-Picasa Gallery Browser    0.6    
-Trad Fr de Tinyportal v1.0 RC1    1.0 RC1
-TinyPortal    1.104


john013

merci c parfait les 2 problèmes résolut .
www.ssd-handball.com
smf 2.0
tp 1.104
Trad Fr de Tinyportal v1.0 RC1
theme epic 2.0
mode:  -Add GooglePlus to Posts    1.0    
-FB & Twitter Sharer Mod 2.0    2.0    
-Picasa Gallery Browser    0.6    
-Trad Fr de Tinyportal v1.0 RC1    1.0 RC1
-TinyPortal    1.104

john013

en fait non il me sort
"Incorrect parameter count in the call to native function 'FIND_IN_SET'
Fichier: /Sources/TPortalAdmin.php
Ligne: 1525"
quand je veut gérer les article
www.ssd-handball.com
smf 2.0
tp 1.104
Trad Fr de Tinyportal v1.0 RC1
theme epic 2.0
mode:  -Add GooglePlus to Posts    1.0    
-FB & Twitter Sharer Mod 2.0    2.0    
-Picasa Gallery Browser    0.6    
-Trad Fr de Tinyportal v1.0 RC1    1.0 RC1
-TinyPortal    1.104

IchBin

Please attach Sources/TPortal.php

Google translate:
S'il vous plaît joignez Sources/TPortal.php

john013

voici le fichier // fetch categories and subcategories
if(!isset($show_nocategory))
{
$request = $smcFunc['db_query']('', '
SELECT DISTINCT var.id as id, var.value1 as name, var.value2 as parent
FROM {db_prefix}tp_variables AS var
WHERE var.type = {string:type}
{string:whereval}
ORDER BY parent, id DESC',
array('type' => 'category', 'whereval' => isset($where) ? 'AND var.value2 = ' . $where : '')
);

if($smcFunc['db_num_rows']($request) > 0)
{
$context['TPortal']['basecats'] = isset($where) ? array($where) : array('0', '9999');
$cats = array();
$context['TPortal']['cats'] = array();
$sorted = array();
while ($row = $smcFunc['db_fetch_assoc']($request))
{
$row['name'] = html_entity_decode($row['name'], ENT_QUOTES, $context['character_set']);
$sorted[$row['id']] = $row;
$cats[] = $row['id'];
}
$smcFunc['db_free_result']($request);
if(count($sorted) > 1)
$context['TPortal']['cats'] = chain('id', 'parent', 'name', $sorted);
else
$context['TPortal']['cats'] = $sorted;
}
}

if(isset($show_submission) && $context['TPortal']['total_submissions'] > 0)
{
// clean up notices
$request2 =  $smcFunc['db_query']('', '
SELECT id, value5
FROM {db_prefix}tp_variables
WHERE type = {string:type}',
array('type' => 'art_not_approved')
);
if($smcFunc['db_num_rows']($request2) > 0)
{
$ids = array();
while($row = $smcFunc['db_fetch_assoc']($request2))
$ids[$row['id']] = $row['value5'];
$smcFunc['db_free_result']($request2);
}
$request = $smcFunc['db_query']('', '
SELECT id, approved
FROM {db_prefix}tp_articles
WHERE FIND_IN_SET(id, {array_int:ids})',
array('ids' => $ids)
);
if($smcFunc['db_num_rows']($request) > 0)
{
while($row = $smcFunc['db_fetch_assoc']($request))
{

}
$smcFunc['db_free_result']($request);
}
www.ssd-handball.com
smf 2.0
tp 1.104
Trad Fr de Tinyportal v1.0 RC1
theme epic 2.0
mode:  -Add GooglePlus to Posts    1.0    
-FB & Twitter Sharer Mod 2.0    2.0    
-Picasa Gallery Browser    0.6    
-Trad Fr de Tinyportal v1.0 RC1    1.0 RC1
-TinyPortal    1.104

IchBin

Remove this section:
$request = $smcFunc['db_query']('', '
SELECT id, approved
FROM {db_prefix}tp_articles
WHERE FIND_IN_SET(id, {array_int:ids})',
array('ids' => $ids)
);
if($smcFunc['db_num_rows']($request) > 0)
{
while($row = $smcFunc['db_fetch_assoc']($request))
{

}
$smcFunc['db_free_result']($request);
}

john013

bonjour,
celà re fonctionne , merci
par-contre quand une personne autoriser veux éditer un texte qu'il a écrit il voie le texte effacé, comment faire?  moi en mode admin pas de souci.
www.ssd-handball.com
smf 2.0
tp 1.104
Trad Fr de Tinyportal v1.0 RC1
theme epic 2.0
mode:  -Add GooglePlus to Posts    1.0    
-FB & Twitter Sharer Mod 2.0    2.0    
-Picasa Gallery Browser    0.6    
-Trad Fr de Tinyportal v1.0 RC1    1.0 RC1
-TinyPortal    1.104

john013

www.ssd-handball.com
smf 2.0
tp 1.104
Trad Fr de Tinyportal v1.0 RC1
theme epic 2.0
mode:  -Add GooglePlus to Posts    1.0    
-FB & Twitter Sharer Mod 2.0    2.0    
-Picasa Gallery Browser    0.6    
-Trad Fr de Tinyportal v1.0 RC1    1.0 RC1
-TinyPortal    1.104

IchBin

Sorry I don't understand what you are asking.