News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

SimplePortal

Started by SimplePortal Team, March 10, 2008, 11:16:07 PM

Previous topic - Next topic

[SiNaN]

Quote from: Tiribulus on February 07, 2009, 03:47:22 PM
For some reason I am having no end of woe. Ignoring the dropmenu thing gets me this:

Database Error
Table 'smf2.sp_articles' doesn't exist
File: /srv/www/htdocs/forum1/Packages/temp/install2.php
Line: 50

and it doesn't install.

Maybe I should delete the folder and database and start over. This is a totally beta forum anyway.

That's because you already have those tables on your database. Removing those tables from your database or the install script inside the package should do it. That's a known issue about SMF database functions.
Former SMF Core Developer | My Mods | SimplePortal

Tiribulus

Quote from: Blue Dream on February 07, 2009, 03:48:47 PM
Quote from: Tiribulus on February 07, 2009, 03:47:22 PM
For some reason I am having no end of woe. Ignoring the dropmenu thing gets me this:

Database Error
Table 'smf2.sp_articles' doesn't exist
File: /srv/www/htdocs/forum1/Packages/temp/install2.php
Line: 50

and it doesn't install.

Maybe I should delete the folder and database and start over. This is a totally beta forum anyway.

That's because you already have those tables on your database. Removing those tables from your database or the install script inside the package should do it. That's a known issue about SMF database functions.

The error says that table doesn't exist, you're it's because it DOES already exist? I'm definitely not arguing, just trying to understand. When I search for that table in the DB I get no results.

As for the install script, are you saying to remove this:

// Finally create the Articles table.
$smcFunc['db_create_table']('sp_articles', $columns, $indexes, array(), 'update_remove');

// Set up the columns for the Blocks Table
$columns = array(
array(
'name' => 'id_block',
'type' => 'int',
'size' => '10',
'auto' => true,
),
array(
'name' => 'label',
'type' => 'tinytext',
),
array(
'name' => 'type',
'type' => 'text',
),
array(
'name' => 'content',
'type' => 'text',
),
array(
'name' => 'parameters',
'type' => 'tinytext',
),
array(
'name' => 'col',
'type' => 'tinyint',
'size' => '4',
'default' => 0,
),
array(
'name' => 'row',
'type' => 'tinyint',
'size' => '4',
'default' => 0,
),
array(
'name' => 'state',
'type' => 'tinyint',
'size' => '4',
'default' => 1,
),
array(
'name' => 'allowed_groups',
'type' => 'text',
'size' => '4',
),
array(
'name' => 'force_view',
'type' => 'tinyint',
'size' => '2',
'default' => 0,
),
array(
'name' => 'permission_type',
'type' => 'tinyint',
'size' => '2',
'default' => 0,
),
array(
'name' => 'display',
'type' => 'text',
),
);


?

Thanks BTW.

KahneFan

PerryM, I received the same error, but as BD says, it's OK to skip it, it still runs fine.
#eric_on_twit| (video) Creating Themes for SMF | Reset Your Forum
NOTE: No PM's for support please.

PerryM

Quote from: KahneFan on February 07, 2009, 04:14:17 PM
PerryM, I received the same error, but as BD says, it's OK to skip it, it still runs fine.

Yea, I'm up and running.  Thanks for the concern, I appreciate it.
Perry

[SiNaN]

Quote from: Tiribulus on February 07, 2009, 04:08:40 PM
The error says that table doesn't exist, you're it's because it DOES already exist? I'm definitely not arguing, just trying to understand. When I search for that table in the DB I get no results.

Yeah, I'm pretty sure that they exists (Error doesn't say that, I know). Have you checked smf_sp_articles ({your_db_prefix}sp_articles) table?

Extract package; remove install2.php file; pack it up again; use that package.
Former SMF Core Developer | My Mods | SimplePortal

PerryM

#1845
I have upgraded my smf to 2.0 RC1 now and everything looks fine.

However I have a post that I added to my front page on SimplePortal and now want to remove it from that page - I don't see how to do this.

I never did it on Beta 4 so I'm assuming its not a bug but just how do I remove the post (not the real post) from the front page?

I got it on the front page by clicking "Add and Article" on the post - it should have changed to "Remove this Article" to make it easy.

Thanks,
Perry

[SiNaN]

You can manage your articles from

Admin CP >> SimplePortal >> Articles

area.

Quote from: PerryM on February 07, 2009, 04:37:39 PMI got it on the front page by clicking "Add and Article" on the post - it should have changed to "Remove this Article" to make it easy.

and yeah, a good idea. Thanks, noted.
Former SMF Core Developer | My Mods | SimplePortal

PerryM

Quote from: Blue Dream on February 07, 2009, 04:48:46 PM
You can manage your articles from

Admin CP >> SimplePortal >> Articles

area.

Quote from: PerryM on February 07, 2009, 04:37:39 PMI got it on the front page by clicking "Add and Article" on the post - it should have changed to "Remove this Article" to make it easy.

and yeah, a good idea. Thanks, noted.

I've been there and I see no articles to delete.  It seems to bring me to the Articles Module which is independent of your module.  I've never added an article in that system.

I'm stumped...
Perry

Tiribulus

Quote from: Blue Dream on February 07, 2009, 04:22:26 PM
Quote from: Tiribulus on February 07, 2009, 04:08:40 PM
The error says that table doesn't exist, you're it's because it DOES already exist? I'm definitely not arguing, just trying to understand. When I search for that table in the DB I get no results.

Yeah, I'm pretty sure that they exists (Error doesn't say that, I know). Have you checked smf_sp_articles ({your_db_prefix}sp_articles) table?

Extract package; remove install2.php file; pack it up again; use that package.

You're right the table is there. I'm using Webmin on a Linux box for this and I must have misspelled the table name before, but manually looking through  the tables I see it there. However, running the installer without install2.php, ignoring the dropmenu.css error got me a blank white browser display and then going back into packages shows nothing installed. This isn't any kind of emergency as this forum is just for me to eventually get used to 2.0. I do appreciate your help though.

[SiNaN]

Quote from: PerryM on February 07, 2009, 04:53:28 PM
I've been there and I see no articles to delete.  It seems to bring me to the Articles Module which is independent of your module.  I've never added an article in that system.

I'm stumped...

I guess you have a mod using the same admin area. Can you link to the mod?

Quote from: Tiribulus on February 07, 2009, 04:56:50 PM
You're right the table is there. I'm using Webmin on a Linux box for this and I must have misspelled the table name before, but manually looking through  the tables I see it there. However, running the installer without install2.php, ignoring the dropmenu.css error got me a blank white browser display and then going back into packages shows nothing installed. This isn't any kind of emergency as this forum is just for me to eventually get used to 2.0. I do appreciate your help though.

Looks like it didn't like file not being there. Would you try the attached package?

Former SMF Core Developer | My Mods | SimplePortal

PerryM

#1850
I have SMF Articles installed and it seems to have some problems - won't install in RC1. 

I went back to  backups and brought up Beta 4 again and then tried to uninstall SMF Articles and got this error message:

5. Execute Modification ./Sources/Admin.php Test failed
  1. Replace ./Sources/Admin.php Test failed

6. Execute Modification ./Sources/Subs.php Test failed
  1. Replace ./Sources/Subs.php Test failed
  2. Replace ./Sources/Subs.php Test failed

7. Execute Modification ./Sources/ManagePermissions.php Test failed
  1. Replace ./Sources/ManagePermissions.php Test failed
  2. Replace ./Sources/ManagePermissions.php Test failed

8. Delete File ./Sources/Articles2.php

I'm guessing there is a conflict between the two modules?

Yes there is a conflict.

On a brand new install of just RC1 and SimplePortal I get a totally different "article List" and "Add Article" then if SMF Articles is installed.

I'm ok, no big deal.  But there is a conflict.

P.S.
Now that I see your "Article List" page I see how to remove an article.  Is there a way to change the order of the articles?

Thanks,
Perry

Tiribulus

Quote from: Blue Dream on February 07, 2009, 04:59:28 PM
. Would you try the attached package?

It looks like that worked with the only weirdness being the copyright stuff kinda stacked on the bottom. What did you wind up doing if you don't mind my asking?
Thanks

[SiNaN]

PerryM:

Thanks for informing. Looks like we will be changing a lot with the new version.

Tiribulus:

Just removed this code from package_info.xml:

<code>install2.php</code>

That code was there to run the install script, you know what would happen when you remove it.

And for copyright, press Ctrl+F5 and that should fix it. Mod makes a change in style.css, which is cached by the browser and hard refresh would make it turn into normal. Fixed that in the next version FYI.
Former SMF Core Developer | My Mods | SimplePortal

Tiribulus

#1853
Quote from: Blue Dream on February 07, 2009, 05:18:15 PM
<<< Tiribulus:

Just removed this code from package_info.xml:

<code>install2.php</code>

That code was there to run the install script, you know what would happen when you remove it.

And for copyright, press Ctrl+F5 and that should fix it. Mod makes a change in style.css, which is cached by the browser and hard refresh would make it turn into normal. Fixed that in the next version FYI.

You're a scary dude 8)
Thanks

Man I wish I would have started fiddling with this stuff years ago.

edemars

I suppose I can do this manually, but with Package Manager I get this:

SMF 2.0 RC1
SimplePortal 2.1.1


Quote
11.     Execute Modification     ./Sources/Admin.php     Test failed
      1.    Replace    ./Sources/Admin.php    Test successful
      2.    Replace    ./Sources/Admin.php    Test failed
      3.    Replace    ./Sources/Admin.php    Test successful
      4.    Replace    ./Sources/Admin.php    Test successful

navjotjsingh

#1855
Quote from: Blue Dream on February 07, 2009, 03:10:51 PM
dropmenu.css edit is okay to ignore.

----

It does not fail in Subs.php. There should be a problem with your files, as I myself have installed it more than 10 times in the last two days. Which edit is that?

It seems, Pretty Urls was installed first and it was causing error. The code which failed was :


global $scripturl, $context, $modSettings, $db_show_debug, $db_cache;

   // In case we have mail to send, better do that - as obExit doesn't always quite make it...
   if (!empty($context['flush_mail']))
      AddMailQueue(true);

   $add = preg_match('~^(ftp|http)?://~', $setLocation) == 0 && substr($setLocation, 0, 6) != 'about:';
   
   // Redirect to the forums action not the portal, when Simple Portal is active.
   if((empty($setLocation) || $scripturl == $setLocation) && !empty($modSettings['portalactive']) && empty($modSettings['sp_disableForumRedirect'])) $setLocation = 'action=forum';
[/forum]

Now here, prettyurl added one more variable in the first global line called $sourcedir which was resulting in the fail. I would suggest to make the package installer to only add the last line.

PerryM

Quote from: navjotjsingh on February 09, 2009, 07:00:09 AM
Quote from: Blue Dream on February 07, 2009, 03:10:51 PM
dropmenu.css edit is okay to ignore.

----

It does not fail in Subs.php. There should be a problem with your files, as I myself have installed it more than 10 times in the last two days. Which edit is that?

It seems, Pretty Urls was installed first and it was causing error. The code which failed was :


global $scripturl, $context, $modSettings, $db_show_debug, $db_cache;

// In case we have mail to send, better do that - as obExit doesn't always quite make it...
if (!empty($context['flush_mail']))
AddMailQueue(true);

$add = preg_match('~^(ftp|http)[s]?://~', $setLocation) == 0 && substr($setLocation, 0, 6) != 'about:';

// Redirect to the forums action not the portal, when Simple Portal is active. ;)
if((empty($setLocation) || $scripturl == $setLocation) && !empty($modSettings['portalactive']) && empty($modSettings['sp_disableForumRedirect'])) $setLocation = 'action=forum';
[/forum]

Now here, prettyurl added one more variable in the first global line called $sourcedir which was resulting in the fail. I would suggest to make the package installer to only add the last line.


Pretty URLs causes a lot of module to screw up - you just can't use it; at least I don't.
Perry

[SiNaN]

edemars:

Ignore the error and install the mod. Make that edit manually.

Of course, don't forget to take back-ups.

navjotjsingh:

Thanks for informing, I'll change that edit then. For now, you can make the change manually.
Former SMF Core Developer | My Mods | SimplePortal

navjotjsingh

I have done the edit and its working perfectly.

PerryM

#1859
I love this module!!!

A suggestion: articles displayed on the front page should follow the permissions under the forum they were created.  E.g. a forum for a Guest should display ONLY to guests on the front page.  A Gold Member (like I sell) should ONLY see Gold Member posts on the front page.

Another suggestion:
I really need a Wiki type thread - just the top post would allow anyone with permission to post to that thread to change just the top/first post.  The old post would simply be deleted and put in a Wiki holding forum so the Admin could go back and make an old post the current one.

That's it, no need to compare posts or have the [new page] type of stuff - if I want to link somewhere I can do it by hand with the Insert Hyperlink.


But what you have now is fantastic and thanks for the hard work.
Perry

Advertisement: