2018-04-22, 05:59 PM
Pages: 1 2
2018-04-23, 03:52 AM
cheers for that thanks.
Haven't played with mysql much though I do know some very limited things.
Need to learn it a bit more.
Haven't played with mysql much though I do know some very limited things.
Need to learn it a bit more.
2018-04-23, 09:42 AM
At this one:
$curper=substr($mpr['displaystyle'],0,-1);
The function substr(0,-1) in that case, removes last symbol from the DB result, in my case this is %.
If you want remove function and leave it only:
$curper=$mpr['displaystyle'];
$curper=substr($mpr['displaystyle'],0,-1);
The function substr(0,-1) in that case, removes last symbol from the DB result, in my case this is %.
If you want remove function and leave it only:
$curper=$mpr['displaystyle'];
2018-05-23, 08:59 AM
I have pulled this code out again and looking to make it a blog.
This is what I have so far.
https://cajgo-support.com/blog.php
Its pulling info from this forum.
https://community.cajgo-support.com/forum-23.html
I need to work out how to style it show a snippet of text and hide the login or modify it to use the sites frontpage header and footer instead of the forums which is probably what I will do.
If anyone can advise how to get a snippet of the actual post in the blog and forward back buttons so say 10 posts are shown on a page that would be great.
Also what codes I need to show the number of replies.
These are my plans:
I have another test file with code I will try to look at integrating part of that, though this other code doesn't grab from the mysql but uses mybb hooks.
This is what I have so far.
https://cajgo-support.com/blog.php
Its pulling info from this forum.
https://community.cajgo-support.com/forum-23.html
I need to work out how to style it show a snippet of text and hide the login or modify it to use the sites frontpage header and footer instead of the forums which is probably what I will do.
If anyone can advise how to get a snippet of the actual post in the blog and forward back buttons so say 10 posts are shown on a page that would be great.
Also what codes I need to show the number of replies.
These are my plans:
- Integrate the front page bootstrap header and footer
- Show a snippet of text for the post and add a read more button
- Style the page
- Show number of replies
I have another test file with code I will try to look at integrating part of that, though this other code doesn't grab from the mysql but uses mybb hooks.
2018-05-25, 10:55 AM
(2018-05-23, 08:59 AM)drguild Wrote: [ -> ]These are my plans:If anyone else has ideas I could do for the posts let me know.
- Integrate the front page bootstrap header and footer
- Show a snippet of text for the post and add a read more button
- Style the page
- Show number of replies
I have another test file with code I will try to look at integrating part of that, though this other code doesn't grab from the mysql but uses mybb hooks.
To show, lets say first 50 characters + Show more after:
if (strlen($result)>50){$showmorebutton=" Show more...";}else{$showmorebutton="";};
$result = substr($myStr, 0, 50);
$mypost=$result.$showmorebutton;
After that you can style $showmorebutton whatever you want
2018-05-25, 11:08 AM
Thanks for the tip atm I am using the other code that hooks into mybb that was posted I will pm you about things.
Pages: 1 2