Lin2age (Interlude)
Login server:
Online

Game server:
Online

Players online:
1
Vote on the Lineage 2 Top 200
Vote on the Lineage 2 Top 200

xx SMF1 Trying to get Auto_increment value.

Yesterday at 07:02:23 PM by MrMorph
This is my code :

Code: [Select]
global $db_prefix, $db_name;

$result = db_query("
SHOW TABLE STATUS
FROM $db_name
LIKE '{$db_prefix}my_table'"
, false, false);

$row = mysql_fetch_assoc($result);

But when run $row['Auto_increment'] contains nothing.

When I do this :

Code: [Select]
global $db_prefix, $db_name;

$result = db_query("
SHOW TABLE STATUS
FROM $db_name
LIKE 'my_table'"
, false, false);

$row = mysql_fetch_assoc($result);

It returns a value.  The only difference is that the $db_prefix is left off.

Anyone see what I have done wrong please ?
3 comments | Write Comment

xx Function like Ikonboard's "Ultimate News"?

May 17, 2012, 12:57:20 PM by BinkyM
Hi, SMF peeps:

I've tried searching everywhere for this, and I just can't find it, but perhaps it's been tackled already and called something else and I don't know it? Or maybe it exists already and I just don't know the nomenclature? (That'd be great!) If not, I'd really appreciate someone helping me with it.

In Ikonboard, you can output text files with all sortsa handy tags, but I like to just output the URLs and titles of the five most recent posts in each forum. Then I use an SSI include to stick it on my home page (which isn't the forum) with a heading like "Latest Posts in the Science & Technology Forum," or "New in the Current Events Forum," and so on. IOW, it's like a sampling of what's going on in the forums and it's up-to-the-minute. Very spiderable.

Does this exist in the software already? If not, is there a mod for this? If not, would someone be so kind as to help me create it? I'd be really grateful, and I'll bet the folks reading the "Tips & Tricks" section would think it's neat!

Thanks very much,

Binky
5 comments | Write Comment

solved PHP shouldn't show an "Older" button

May 16, 2012, 01:49:15 PM by Dr. Deejay
Hi all! :) I was about to release my blogging software, so I decided to throw an alpha version to Yoshi, we tested it out for a while and we came to the conclusion that the pagination script.. well, it sucks. :( So here is what it does: it displays the 'older' button correctly, but it's a bit enthusiastic and shows an 'Older' button too when there are no things left on the next page. I've tried several things, but I can't get it fixed. Could someone please take a look at it? :)

This is the code that should display it:
Code: [Select]
// Do we even NEED to show more?
if(($vienara['show'] > ($vienara['blog_count'] -1)) && ($vienara['blogs_to_show'] < $vienara['setting']['blogsperpage'])) {

// Output the button.
if($vienara['setting']['order'] == 'asc')
echo '
<a href="' . Blog_file . '?show=' . $vienara['show'] . '" class="more whitelink">' . show_string('newer') . '</a>';
else
echo '
<a href="' . Blog_file . '?show=' . $vienara['show'] . '" class="more whitelink">' . show_string('older') . '</a>';
}

And this is the piece of code that gets the variables:
Code: [Select]
// We need to calculate how many results we should show
if(isset($_GET['show']) && is_numeric($_GET['show']))
$vienara['show'] = $_GET['show'] + $vienara['setting']['blogsperpage'];
else
$vienara['show'] = $vienara['setting']['blogsperpage'];

// We should begin with a specific number of blogs. How many?
if(!empty($_GET['show']) && is_numeric($_GET['show']))
$vienara['blogs_to_show'] = $_GET['show'];

// Just begin with the first blog.
else
$vienara['blogs_to_show'] = 0;

And this gets the blog count:
Code: [Select]
// Get the blogcount
$vienara['blog_count'] = xensql_count_rows("
RETRIEVE id_blog, blog_title, blog_content, published, post_date
FROM {db_pref}content
WHERE published is equal to 1
");

Thanks in advance! :)
3 comments | Write Comment

clip SMF plugin for PayPlans

May 16, 2012, 04:18:54 AM by capeinfo
Hi

Is there anyone who can help develop a PayPlans app for SMF so that PayPlans can be used for subscriptions and a variety of payment gateways?

PayPlans say the easiest way to develop the plugin is to adapt an existing one and they're willing to help if the developer runs into problems.  Their guidelines for developing apps is at http://www.jpayplans.com/support/documentation/item/developing-apps-2.html?category_id=116

I'm attaching the plugin for Kunena as an example.

Thanks
Carl
0 comments | Write Comment

clip Need help modifying the New Topic link into a button

May 16, 2012, 03:14:58 AM by perrine1
Ok so i installed the theme called B-Cream and i wanted to ask how can i possibly change the text that says "New Topic"  and make them into a button.

Also how can i change the text to say something else like "Add new Post" Or "New Post" or any phrase I want it to say.




Thank you in advance
0 comments | Write Comment