Mysidia Adoptables Support Forum  

Home Community Mys-Script Creative Off-Topic
Go Back   Mysidia Adoptables Support Forum > Mysidia Adoptables > Addons and Modifications > Mys v1.3.x Mods

Notices

Reply
 
Thread Tools Display Modes
  #11  
Old 02-24-2014, 09:37 AM
Vaporman87 Vaporman87 is offline
Member
 
Join Date: Feb 2014
Posts: 32
Gender: Male
Credits: 4,881
Vaporman87 is on a distinguished road
Default

The only thing I noticed is that if you have your site in a subfolder, you need to go in and change the following code in the /view/newsview.php file:

Code:
$newsObj = new News($news);
        		$index++;
        		$newsField = new Fieldset("news$index");
      			$comments = $newsObj->getCommentNumber();
        		$newsField->add(new Comment("<span class='date'>Date: {$newsObj->getDate()}</span><br>",FALSE));
        		$newsField->add(new Comment("<span class='title'>{$newsObj->getTitle()}</span>",FALSE));
        		$newsField->add(new Comment("<span class='author'>by <a href='/profile/view/{$newsObj->getUserObject()->getUsername()}' target='_blank'>{$newsObj->getUserObject()->getUsername()}</a></span>",FALSE));
        		$newsField->add(new Comment("<span class='comment'><a href='/news/view/{$newsObj->getID()}'>Comments({$comments})</a></span><br>",FALSE));
        		$newsField->add(new Comment("<span class='content'><img class='authorimg' src='{$newsObj->getUserObject()->getprofile()->getavatar()}'>{$newsObj->getContent()}</span>",FALSE));
I added my subfolder name, "DigiChars", before the " /news/view/ " and " /profile/view/ " text.
Reply With Quote
  #12  
Old 02-25-2014, 08:55 AM
IntoRain's Avatar
IntoRain IntoRain is offline
Moderator
 
Join Date: Jul 2013
Location: Portugal
Posts: 461
Gender: Female
Credits: 19,259
IntoRain is on a distinguished road
Default

Thank you! I will add a note to the first post!
__________________


asp.net stole my soul.
Reply With Quote
  #13  
Old 02-26-2014, 08:36 PM
Missy Master's Avatar
Missy Master Missy Master is offline
Pet-Sim.Online
 
Join Date: Jan 2010
Posts: 475
Gender: Unknown/Other
Credits: 44,524
Missy Master is an unknown quantity at this point
Default

This looks really good! I cant wait to try this out --- thanks for sharing this with us! :)
Reply With Quote
  #14  
Old 03-03-2014, 06:55 PM
IntoRain's Avatar
IntoRain IntoRain is offline
Moderator
 
Join Date: Jul 2013
Location: Portugal
Posts: 461
Gender: Female
Credits: 19,259
IntoRain is on a distinguished road
Default

Quote:
Originally Posted by Annatar View Post
This looks really good! I cant wait to try this out --- thanks for sharing this with us! :)
Thank you for the support! ^^
__________________


asp.net stole my soul.
Reply With Quote
  #15  
Old 03-05-2014, 01:21 AM
Kesstryl's Avatar
Kesstryl Kesstryl is offline
Member
 
Join Date: Feb 2012
Posts: 125
Gender: Female
Credits: 17,016
Kesstryl is on a distinguished road
Default

Nice mod, will definitely use this once I start working on my site. Right now I've been diggin g deep into learning MVC, OOP, and PDO before I even touch Mysidia.
Reply With Quote
  #16  
Old 03-07-2014, 06:01 PM
Abronsyth's Avatar
Abronsyth Abronsyth is offline
A Headache Embodied
 
Join Date: Aug 2011
Location: NY
Posts: 1,011
Gender: Male
Credits: 111,697
Abronsyth is on a distinguished road
Default

Just created and added everything and it is functioning perfectly! I have to fix up the formatting a little bit so it works more neatly with the theme, but it's awesome so far!

How do you think one should go about making it so that a news alert appears at the top of the page until the member visits the news page? So each time a new news post is added members are alerted when they logon?
__________________
My Mods Site (1.3.4, 2020 Mods)
Reply With Quote
  #17  
Old 03-09-2014, 08:16 PM
IntoRain's Avatar
IntoRain IntoRain is offline
Moderator
 
Join Date: Jul 2013
Location: Portugal
Posts: 461
Gender: Female
Credits: 19,259
IntoRain is on a distinguished road
Default

Quote:
Originally Posted by Kesstryl View Post
Nice mod, will definitely use this once I start working on my site. Right now I've been diggin g deep into learning MVC, OOP, and PDO before I even touch Mysidia.
Thank you! Hope it works well for you! ^^ OOP is one of those concepts that will make so much sense once it clicks xD

Quote:
Originally Posted by Abronsyth View Post
Just created and added everything and it is functioning perfectly! I have to fix up the formatting a little bit so it works more neatly with the theme, but it's awesome so far!

How do you think one should go about making it so that a news alert appears at the top of the page until the member visits the news page? So each time a new news post is added members are alerted when they logon?
Yay glad it worked for you! ^^ THank you for the input!
I was thinking of sending a new message to users to alert them of a new news, but I kinda got lazy and didn't do it lol
I guess it would work exactly like the messages system that alerts users when they get a new message. Maybe another table that contains all users and a field that says if they have been to the news page ever since a new news was posted. So when posting a news, all fields would reset to "unread" for all users and while it was unread, a message would appear somewhere in the site
__________________


asp.net stole my soul.
Reply With Quote
  #18  
Old 09-24-2014, 06:26 PM
Abronsyth's Avatar
Abronsyth Abronsyth is offline
A Headache Embodied
 
Join Date: Aug 2011
Location: NY
Posts: 1,011
Gender: Male
Credits: 111,697
Abronsyth is on a distinguished road
Default

Okay, I'm having this error:
CREATE TABLE `newscomments` (

`id` INT( 5 ) NOT NULL AUTO_INCREMENT PRIMARY KEY ,
`newsID` INT( 5 ) NOT NULL DEFAULT 'None',
`userID` INT( 5 ) NOT NULL DEFAULT 'None',
`comment` VARCHAR( 300 ) NULL DEFAULT NULL ,
`date` VARCHAR( 30 ) NULL DEFAULT NULL
) ENGINE = MYISAM
MySQL said: Documentation

#1067 - Invalid default value for 'newsID'

Any ideas?
__________________
My Mods Site (1.3.4, 2020 Mods)
Reply With Quote
  #19  
Old 09-24-2014, 07:10 PM
IntoRain's Avatar
IntoRain IntoRain is offline
Moderator
 
Join Date: Jul 2013
Location: Portugal
Posts: 461
Gender: Female
Credits: 19,259
IntoRain is on a distinguished road
Default

Quote:
Originally Posted by Abronsyth View Post
Okay, I'm having this error:
CREATE TABLE `newscomments` (

`id` INT( 5 ) NOT NULL AUTO_INCREMENT PRIMARY KEY ,
`newsID` INT( 5 ) NOT NULL DEFAULT 'None',
`userID` INT( 5 ) NOT NULL DEFAULT 'None',
`comment` VARCHAR( 300 ) NULL DEFAULT NULL ,
`date` VARCHAR( 30 ) NULL DEFAULT NULL
) ENGINE = MYISAM
MySQL said: Documentation

#1067 - Invalid default value for 'newsID'

Any ideas?
Did you write "None" instead of selecting 'None' from the list? If it's not that, you can try running it directly and removing the default part:

Code:
CREATE TABLE  `[your_prefix_here]_newscomments` (

`id` INT( 5 ) NOT NULL AUTO_INCREMENT PRIMARY KEY ,
`newsID` INT( 5 ) NOT NULL,
`userID` INT( 5 ) NOT NULL,
`comment` VARCHAR( 300 ) NULL DEFAULT NULL ,
`date` VARCHAR( 30 ) NULL DEFAULT NULL
) ENGINE = MYISAM
This is by clicking on the "SQL" tab. Like here: http://i.imgur.com/VGRaF82.png
__________________


asp.net stole my soul.
Reply With Quote
  #20  
Old 09-25-2014, 04:37 AM
Abronsyth's Avatar
Abronsyth Abronsyth is offline
A Headache Embodied
 
Join Date: Aug 2011
Location: NY
Posts: 1,011
Gender: Male
Credits: 111,697
Abronsyth is on a distinguished road
Default

The phpMyAdmin that my host is using seems to be a bit dated, so it doesn't actually have a drop-down for most of the parts. I'll go through and run it directly to see if that'll work.

Thank you :)
__________________
My Mods Site (1.3.4, 2020 Mods)
Reply With Quote
Reply

Thread Tools
Display Modes

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

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
News Feed Yuki Night Suggestions and Feature Requests 0 01-30-2013 12:04 AM
Implementing A News Feed Yuki Night Questions and Supports 0 01-29-2013 05:25 PM
News feed script? Aasixx Staff Central 3 06-18-2012 03:06 AM
Adopts News Bloodrun Addons/Mods Graveyard 71 06-18-2009 02:13 PM
News 12345 Questions and Supports 9 05-10-2009 03:13 PM


All times are GMT -5. The time now is 04:25 PM.

Currently Active Users: 458 (0 members and 458 guests)
Threads: 4,080, Posts: 32,024, Members: 2,016
Welcome to our newest members, jolob.
BETA





What's New?

What's Hot?

What's Popular?


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
vBCommerce I v2.0.0 Gold ©2010, PixelFX Studios
vBCredits I v2.0.0 Gold ©2010, PixelFX Studios
Emoticons by darkmoon3636