Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

how to pin post on top? 如何把帖子置顶? #289

Open
hoogw opened this issue Oct 30, 2018 · 1 comment
Open

how to pin post on top? 如何把帖子置顶? #289

hoogw opened this issue Oct 30, 2018 · 1 comment

Comments

@hoogw
Copy link

hoogw commented Oct 30, 2018

I know when edit post, you can click 'Rise' button to pin it on top for 7 days.
If you click again, add 7 more days, and so on.

But I want to permanent pin post on top, no need to click click again again for 7 days.

@hoogw
Copy link
Author

hoogw commented Oct 30, 2018

Solution is make 7 days to 7000 days, by modify code

C:\Apache24\htdocs\carbon\controller\manage.php

              // edit post, click sink, sink 7 days = 604800 second, 

            // I want 7000 days = 604800000

	$this->db->query("UPDATE " . PREFIX . "topics SET LastTime = LastTime-604800000 WHERE ID=:ID", array(

		"ID" => $this->id





           // edit post, click rise, will pin top for 7 days = 604800 second, 

            // I want 7000 days = 604800000

	$this->db->query("UPDATE " . PREFIX . "topics SET LastTime = LastTime+604800000 WHERE ID=:ID", array(

		"ID" => $this->id

	));

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant