форум vBSupport.ru > vBulletin > Вопрос — Ответ > Помогите найти!
Register Меню vBsupport Изображения Files Manager О рекламе Today's Posts Search
  • Родная гавань
  • Блок РКН снят
  • Premoderation
  • For English speaking users
  • Каталог Фрилансеров
  • If you want to buy some product or script
  • Администраторам
VBsupport перешел с домена .ORG на родной .RU Ура! Пожалуйста, обновите свои закладки - VBsupport.ru
Блок РКН снят, форум доступен на всей территории России, включая новые терртории, без VPN
На форуме введена премодерация ВСЕХ новых пользователей

Почта с временных сервисов, типа mailinator.com, gawab.com и/или прочих, которые предоставляют временный почтовый ящик без регистрации и/или почтовый ящик для рассылки спама, отслеживается и блокируется, а так же заносится в спам-блок форума, аккаунты удаляются
for English speaking users:
You may be surprised with restriction of access to the attachments of the forum. The reason is the recent change in vbsupport.org strategy:

- users with reputation < 10 belong to "simple_users" users' group
- if your reputation > 10 then administrator (kerk, Luvilla) can decide to move you into an "improved" group, but only manually

Main idea is to increase motivation of community members to share their ideas and willingness to support to each other. You may write an article for the subject where you are good enough, you may answer questions, you may share vbulletin.com/org content with vbsupport.org users, receiving "thanks" equal your reputation points. We should not only consume, we should produce something.

- you may:
* increase your reputation (doing something useful for another members of community) and being improved
* purchase temporary access to the improved category:
10 $ for 3 months. - this group can download attachments, reputation/posts do not matter.
20 $ for 3 months. - this group can download attachments, reputation/posts do not matter + adds eliminated + Inbox capacity increased + files manager increased permissions.

Please contact kerk or Luvilla regarding payments.

Important!:
- if your reputation will become less then 0, you will be moved into "simple_users" users' group automatically.*
*for temporary groups (pre-paid for 3 months) reputation/posts do not matter.
Уважаемые пользователи!

На форуме открыт новый раздел "Каталог фрилансеров"

и отдельный раздел для платных заказов "Куплю/Закажу"

Если вы хотите приобрести какой то скрипт/продукт/хак из каталогов перечисленных ниже:
Каталог модулей/хаков
Ещё раз обращаем Ваше внимание: всё, что Вы скачиваете и устанавливаете на свой форум, Вы устанавливаете исключительно на свой страх и риск.
Сообщество vBSupport'а физически не в состоянии проверять все стили, хаки и нули, выкладываемые пользователями.
Помните: безопасность Вашего проекта - Ваша забота.
Убедительная просьба: при обнаружении уязвимостей или сомнительных кодов обязательно отписывайтесь в теме хака/стиля
Спасибо за понимание
 
 
 
 
e10ff
Продвинутый
Default ecDownloads v4.XXX вывод последних закачек
0

Многие знакомы с этим замечательным модулем, но вот появилась необходимость вывести на другую пхп страницу, не связанную с воблой, список последних видео файлов. В самом модуле уже имеется такой блок который выводит пятерку последних файлов.
Также у меня есть код который выводит последние темы форума на любую другую страницу, кто-то сможет прикрутить на примере такого кода из модуля ecDownloads колонку последних файлов. У меня чет не выходит... Я уверен многие бы сказали спасибо.
PHP Code:
## CUSTOMIZE SETTINGS FOR YOUR SITE ##
$db_host = "localhost"; // Change this if your MySQL database host is different.
$db_name = ""; // Change this to the name of your database.
$db_user = ""; // Change this to your database username.
$db_pw = ""; // Change this to your database password.

$forum_url = "http://www.site.com.ua/forum/"; // Change this to reflect to your forum's URL.
$forum_id = "27"; // If you wish to display the posts from a specific forum, enter the forum id here. Otherwise, leave it blank.
$limit = "7"; // Number of posts displayed.
$titlecolor = "#0000FF"; // This is the color of the title.
$postedcolor = "#404040"; // This is the color of the bottom text.
$txtlimit = "100"; // This is the character limit.
#######################################

// Connecting to your database
mysql_connect($db_host, $db_user, $db_pw) 
OR die (
"Cannot connect to your database"); 
mysql_select_db($db_name) OR die("Cannot connect to your database"); 

// Below is the beginning of a table. If you feel you don't need it, you may remove it.
echo "<table border=\"0\" width=\"100%\" cellspacing=\"0\" cellpadding=\"2\">";

if (
$forum_id) {
$forumid = "AND forumid=$forum_id";
}

if (
$limit) {
$limited = "LIMIT $limit";
}
$thread_sql = mysql_query("SELECT threadid,title,lastpost,lastposter FROM thread WHERE visible=1 AND open=1 $forumid ORDER BY lastpost DESC $limited");

while(
$thread_get=mysql_fetch_array($thread_sql))
{
$lastpost = $thread_get['lastpost'];
$tid = $thread_get['threadid'];
$psql = mysql_query("SELECT postid FROM post WHERE threadid=$tid ORDER BY postid DESC");
$getp=mysql_fetch_array($psql);
$pid = $getp['postid'];
$title = $thread_get['title'];
$title = substr($title,0,$txtlimit);
echo 
"<tr><td>-&nbsp;<a href=\"$forum_url/showthread.php?p=$pid#post$pid\">$title</a></i></td></tr>";
}
echo 
"</table>"; 
Bot
Yandex Bot Yandex Bot is online now
 
Join Date: 05.05.2005
Реклама на форуме А что у нас тут интересного? =)
 
 
kerk
k0t
 
kerk's Avatar
Default
0

e10ff,
я уже выкладывал файлы и описание, как их прикрутить к странице в теме с ecdownloads
ищи там...
 
 
e10ff
Продвинутый
Default
0

где это там?
 
 
p-s-y
Простоузер
Default
1

Quote:
Originally Posted by e10ff
Многие знакомы с этим замечательным модулем, но вот появилась необходимость вывести на другую пхп страницу, не связанную с воблой, список последних видео файлов. В самом модуле уже имеется такой блок который выводит пятерку последних файлов.
Также у меня есть код который выводит последние темы форума на любую другую страницу, кто-то сможет прикрутить на примере такого кода из модуля ecDownloads колонку последних файлов. У меня чет не выходит... Я уверен многие бы сказали спасибо.
PHP Code:
## CUSTOMIZE SETTINGS FOR YOUR SITE ##
$db_host = "localhost"; // Change this if your MySQL database host is different.
$db_name = ""; // Change this to the name of your database.
$db_user = ""; // Change this to your database username.
$db_pw = ""; // Change this to your database password.

$forum_url = "http://www.site.com.ua/forum/"; // Change this to reflect to your forum's URL.
$forum_id = "27"; // If you wish to display the posts from a specific forum, enter the forum id here. Otherwise, leave it blank.
$limit = "7"; // Number of posts displayed.
$titlecolor = "#0000FF"; // This is the color of the title.
$postedcolor = "#404040"; // This is the color of the bottom text.
$txtlimit = "100"; // This is the character limit.
#######################################

// Connecting to your database
mysql_connect($db_host, $db_user, $db_pw) 
OR die (
"Cannot connect to your database"); 
mysql_select_db($db_name) OR die("Cannot connect to your database"); 

// Below is the beginning of a table. If you feel you don't need it, you may remove it.
echo "<table border=\"0\" width=\"100%\" cellspacing=\"0\" cellpadding=\"2\">";

if (
$forum_id) {
$forumid = "AND forumid=$forum_id";
}

if (
$limit) {
$limited = "LIMIT $limit";
}
$thread_sql = mysql_query("SELECT threadid,title,lastpost,lastposter FROM thread WHERE visible=1 AND open=1 $forumid ORDER BY lastpost DESC $limited");

while(
$thread_get=mysql_fetch_array($thread_sql))
{
$lastpost = $thread_get['lastpost'];
$tid = $thread_get['threadid'];
$psql = mysql_query("SELECT postid FROM post WHERE threadid=$tid ORDER BY postid DESC");
$getp=mysql_fetch_array($psql);
$pid = $getp['postid'];
$title = $thread_get['title'];
$title = substr($title,0,$txtlimit);
echo 
"<tr><td>-&nbsp;<a href=\"$forum_url/showthread.php?p=$pid#post$pid\">$title</a></i></td></tr>";
}
echo 
"</table>"; 
i made somethig like this quite a while ago.
now it looks crapy but before i had the description picture at the right column and the description of the download near the download name, anyway here are to codes...

index.php
PHP Code:
<meta name="DESCRIPTION" content="ддешгеъ жойреъ мощъощйн ъешойн баъш сйобйап-йщшам\рйъп мштрп огй фтн аъ дтоег лгй мшаеъ аъ дтглерйн дазшерйн!">
<TITLE>ддешгеъ жойреъ мощъощйн ъешойн баъш сйобйап-йщшам\рйъп мштрп огй фтн аъ дтоег лгй мшаеъ аъ дтглерйн дазшерйн!</TITLE>
<link rel="stylesheet" type="text/css" href="formate.css">
<?

ob_start
();

////////////////////////////////////////////////////////////
//                 DSDownload © 2005                       //
//             http://dsportal.uw.hu                      //
////////////////////////////////////////////////////////////

include("config.php");

?>
<center>
<table style="text-align: left; width: 500;" border="0"
cellspacing="2" cellpadding="2" class="felsobox">
<tbody>

<tr>
<td style="vertical-align: top;"><center><big><b><i><? echo "ддешгеъ щмре";?></b></i></big></center>
</td>
<br>
<br>
<br>
<br>

<td style="vertical-align: top; width: 40px;"><big><b><center><? echo ""; ?></center></b></big>
</td>
</tr>

</tbody>
</table>
<?php
////
$downcc = mysql_query("SELECT * FROM ".$prefix."dl_images where date LIKE '%$newdownloadDB%' order by date desc") or die(mysql_error());
while ( 
$downwc = mysql_fetch_array($downcc));
$downidd = $downwc["file"];
/////
$downc = mysql_query("SELECT * FROM ".$prefix."dl_files WHERE `purgatory`='0' ORDER BY `date` DESC LIMIT 20") or die(mysql_error());
while ( 
$downw = mysql_fetch_array($downc)) {
$downid = $downw["cid"];

$downsz = mysql_query("SELECT * FROM ".$prefix."dl_files WHERE date='$date' and id='$downid'") or die(mysql_error());
$downszh = mysql_num_rows($downsz);
$downnnn = mysql_num_rows($downc);

///////




/////
if ($downnnn < 1) {
  echo 
"<center><b>$Page_downloadsrn</b></center><br>\n";
}

echo 
"
<table width=\"500\" border=\"0\">
<tr>
<td class=\"space\">
</td>
</tr>

<table style=\"text-align: center; width: 700; height: 50px;\" border=\"2\"
cellspacing=\"2\" cellpadding=\"2\" class=\"downloads\" color=\"#003366\">
<tbody>
<td style=\"vertical-align: top;\"><b><span style=\"text-decoration: underlineg; font-weight: bold, italic;\"><big>    &nbsp;   "
.$downw["name"]."    &nbsp;  </big></span></a></b><br>
</td>
<td style=\"vertical-align: top; width: 40px;\"><b>&nbsp; "
.$downwc["thumb"]."    &nbsp; </b><center><br></center>
</td>
</tr>
</tbody>
</table>"
;

}
?>
<br>
<br>

</form>
<br><br><br><hr><a href="http://www.isymbian.net/">ддешгеъ щмре</a> &copy; сйобйап йщшам 2005-2006
</center>
<? ob_end_flush();  ?>
db.php
PHP Code:
<?php

$dbhost 
= "localhost";
$dbuser = "XXXX";
$dbpass = "XXXX";
$dbname = "XXXX";


$install = "yes";

mysql_connect($dbhost,$dbuser,$dbpass) or die("Error:: can't connect to database");
@
mysql_select_db( "$dbname") or die( "there is no database like $dbname");

$prefix = "";
$enterlang = "English";

//include("language/$enterlang.php");


echo "
<head>
<link rel=\"stylesheet\" type=\"text/css\" href=\"style.css\">
</head>"
;

?>
formate.css ->kinda optional...
PHP Code:
/* Body Gesamt */
body {
    
font-family: Verdana, Arial, Helvetica, sans-serif;
    
font-size: 10pt;
    
font-weight:normal;
    
color: #FFFFFF;
    
margin-top: 10px;
    
background-color: #000000;
}

/* Logo ьber Navigation */
body.style {
    
background-image: url("logo.gif");
    
background-repeat: no-repeat;
    
background-attachment: fixed;
}


/* #### LINKS #### */
a {
    
color: #336699;
    
text-decoration:none;
    
font-weight: bold;
}

a:hover {
    
text-decoration: underline;
}

a.s {
    
color: #990000;
    
font-size: 15pt;
}

a.t {
    
color: #990000;
    
font-size: 15pt;
}


/* #### TABELLEN #### */

table {
    
font-family: Verdana, Arial, Helvetica, sans-serif;
    
font-size: 10pt;
    
color: #FFFFFF;
    
border: 0px solid #000000;
    
margin: 5px auto;
}

th {
    
color: #FFFFFF;
    
font-weight: normal;
    
text-align: center;
    
padding: 0px 10px;
    
border: 1px dotted #FFFFFF;
    /* \*/ 
* border: 1px solid #CCCCCC; /* IE Hack, Rahmen dunkler und solid */
}

td.a { /* ? */
    
height: 37px;
    
text-align: center;
}

td.b { /* Body Nachrichten */
    
color: #FFFFFF;
    
font-weight: normal;
    
font-family: courier;
    
padding: 5px 10px;
    
border: 1px dotted #009900;
    
* font-family:  Verdana, Arial, Helvetica, sans-serif; /* IE Hack, Schriftart wurde im IE5 ьberall Courier */
}

td.b > table { /* Body Nachrichten Tabelle, z.B. Spionagebericht */
    
font-family: courier;
    * 
font-family:  Verdana, Arial, Helvetica, sans-serif; /* IE Hack, Schriftart wurde im IE5 ьberall Courier */
}

td.c { /* Ьberschrift-Zellen: Flotte, Technik, Rohstoffe, Nachrichten, Einstellungen, Nachrichten, Index ### Absenden-Zelle: Flotte, Verteidigung */
    
font-weight: bold;
    
text-align: center;
    
color: #FFFFCC;
    
border: 1px dotted #FFFFCC;
    /* \*/ 
* color: #000000; /* IE Hack, Rahmen raus, Hintergrundfarbe rein. */
    /* \*/ 
* border-width: 0px; /* -"- */
    /* \*/ 
* background-color: #FFFFCC; /* -"- */
}

td.f { /* ? */
    
color: #000000;
    
font-weight: bold;
    
text-align: center;
}

td.g { /* ? */
    
font-weight: bold;
    
text-align: right;
}

td.h { /* ? */
    
color: #000000;
    
text-align: center;
}

td.i { /* ? */
    
color: #FF0000;
    
text-align: center;
}

td.j { /* ? */
    
color: #00FF00;
    
text-align: center;
}

td.k { /* Zellen re: Gebдude, Forschung, Werft, Verteidigung; Rohstoffe:teilw. */
    
text-align: center;
    
font-weight: bold;
    
border: 1px dotted #666666;
    /* \*/ 
* border-width: 2px; /* IE Hack, so sieht der Rahmen einigerm. dotted aus. */
    
padding: 0px 10px;
}

td.l { /* Zellen li und mi: Gebдude, Forschung, Werft, Verteidigung; Technik */
    
font-size: 8pt;
    
border: 1px dotted #666666;
    /* \*/ 
* border-width: 2px; /* IE Hack, so sieht der Rahmen einigerm. dotted aus. */
}

td.m { /* ? */
    
font-weight: bold;
    
text-align: right;
    
width: 86px;
}

td.n { /* Index, in einem leeren td... wenig Sinn */
    
font-weight: bold;
    
text-align: center;
    
width: 88px;
}

td.o { /* ? */ /* Ist ein ekelhaftes blau... aber wo kommt das vor? */
    
text-align: center;
    
color: #0000FF;
}

td.q { /* ? */
    
font-weight: bold;
    
font-size: 12pt;
    
text-align: center;
    
vertical-align: middle;
}

td.r { /* ? */
    
text-align: right;
}

td.v { /* ? */
    
font-weight: bold;
    
text-align: right;
}

div.z { /* Counter Forschung */
    
font-size: 10pt;
    
font-weight: bold;
    
color: #FFFF00;
}

div.z > a { /* Link Counter Abbrechen */
    
font-size: 8pt;
}

/* #### ЬBERSCHRIFTEN #### */

h1 {
    
font-size: 15pt;
    
font-weight: bold;
    
color: #990000;
    
padding: 2px;
    
border-top: 1px dotted #990000;
    
border-bottom: 1px dotted #990000;
    /* \*/ 
* border: 0px; /* Im IE sieht der Rahmen nicht gut aus, also wech damit*/
}

/* #### EINGABEFELDER #### */

input {
    
color: #000000;
    
background-color: #DDDDDD;
    
border: 1px solid #CCCCCC;
    
text-indent: 2px;
    
margin: 3px 0px;
    
font-size: 9pt;
}

input:focus {
    
background-color: #CCCCCC;
}

textarea {
    
color: #000000;
    
background-color: #DDDDDD;
    
border-color: #CCCCCC;
    
border-width: 1px;
    
text-indent: 2px;
}

textarea:focus {
    
background-color: #CCCCCC;
    
color: #000000;
}

select {
    
color:#000000;
    
background-color:#DDDDDD;
}

img { /* Keine Rahmen um (verlinkte) bilder */
    
border: 0px;
}

/* NIX FЬR INTERNET EXPLODER */
a[target="Hauptframe"] { /* Navigation */
    
font-weight: bold;
    
display: block;
    
width: 110;
}

a[target="Hauptframe"]:hover { /* Block-Navigation */
    
display: block;
    
background-color: #CCCCCC;
    
text-decoration: none;

    
border-color: #336699;
    
border-style: none;
}

font[color="#00ff00"] { /* grьn wenn gebaut werden kann */
    
color: #669933;
}

font[color="#ff0000"]{ /* rot wenn nicht gebaut werden kann */
    
color: #993333;
}

img[width="42"][height="22"] { /* Ressourcen-Bilder */
    
padding-bottom: 10px;
}

img[width="120"][height="120"] { /* Bilder */
    
padding: 2px;
}

img[width="120"][height="120"] { /* Nur Mozi */
    
-moz-opacity:0.7;
}

img[width="120"][height="120"]:hover { /* Nur Mozi */
    
-moz-opacity:1;
}

input[type="submit"] { /* Submit-Button ein bisschen grцЯer */
    
font-size: 10pt;
} 
if you make the code cleaner and better-looking post it pliz.

PS:
its now set to display latest 20 download names, to change it edit index.php at line 41

Quote:
$downc = mysql_query("SELECT * FROM ".$prefix."dl_files WHERE `purgatory`='0' ORDER BY `date` DESC LIMIT 20"
change the DESC LIMIT 20 to whatever you like it to show.
 


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off




All times are GMT +4. The time now is 12:46 PM.


Powered by vBulletin® Version Anime Edition
Copyright ©2000 - 2026, Jelsoft Enterprises Ltd.