Static Comments System for Jekyll [closed] - static

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 6 years ago.
Improve this question
My blog currently runs Jekyll and the Minimal Mistakes theme, and uses the theme's built in functionality to add the Disqus comments system.
This JavaScript-based commenting system, to me sort of defeats the purpose of having a static blog in Jekyll, considering:
Its JavaScript creates a decisively non-static page.
Comments are not stored with the website.
Comments are stored in some database instead of flat-text files.
My question is, therefore: What is a suitable system for comments that stays as close to the Jekyll philosophy as possible (an ideally runs on gh-pages)?
I found several possible candidates:
Isso is a comments system which is looks similar to Disqus, it works with a SQLite database
Jekyll::StaticComments seems pretty suitable, but it means you have to manually add the comments from emails.
Are there any other options? If so, what would work with gh-pages, and what would work on a self-hosted Jekyll blog?

Here's another solution which is dynamic and uses JavaScript, but doesn't store the comments at a 3rd party provider:
This guy made a static website with Jekyll, but uses GitHub's issue tracker to create his comments.
He uses GitHub Pages to host his blog, and for each new post, he creates a new issue in his blog's repository.
Then, he uses JavaScript to get the issue's comments from the GitHub API and show it on the page.
Here's a blog post which explains how to set this up:
GitHub hosted comments for GitHub hosted blogs

Whether a javascript loaded, externally hosted comment system "defeats the purpose" of a static site is a matter of opinion.
For me, the point is to be able to host the site as entirely static resources, to take advantage of caching, CDN, distributed hosting, etc. I have seen huge advantages to that, and externally hosting my comments doesn't conflict at all.
That being said, it's an interesting question.
Isso (like Disqus) uses JS on the client side and requires server side software (Python based) that you have to manage, so it doesn't seem like this is any closer to your ideal.
Jekyll::StaticComments is in the right direction, but it's not supported on gh-pages if you have GitHub processing your Jekyll site (you can of course generate the static site yourself and then host it on GitHub Pages).
You also need a way for users to submit comments, and then to get those comments into a file that can be used by the generation process (not necessarily via email as you thought though).
So you need to take comments from somewhere, possibly email, possibly yet another third party hosted app (SimpleForm maybe).
And then you need to manually put them into the YAML site, regenerate, then publish, or, you can set up an automated build process for your site, which can pull the user submitted content when available and build and publish automatically.
Other than manually accepting comments through an off-site medium, you're going to deal with something dynamic somewhere.

Related

How to Prevent from re-uploading a file? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 9 years ago.
Improve this question
i have an Educational website and i create always pdf files from my learning and ad them for download
but there is many learchers that download my files and reupload them somewhere else
i used google dmca but is there any way to Prevent from re-uploading my files?
One way is to use your .htaccess to prevent hotlinking, but even if you do that, you'll again have the problem that when someone views the document via an in-browser extension (e.g. Adobe Reader, Foxit PDF Reader), they can save it and you've lost control over what they can do with it. Or, depending on how you've set up your site, they can simply directly download it, leaving you again back at square one.
Hence, the solution is to bypass direct access to the document. And, there are a number of ways to do that, which varies based on technique and web software (platform) used.
However, since you didn't mention a particular platform or technology: you can use web controllers (MVC type controllers) to broker the dynamic viewing and displaying of the documents in tandem with a client-side tool / plugin to do the displaying for you (much like Scribd).
However, Scribd uses a proprietary Flash PDF viewer called iPaper, and while it isn't available for use, you can find many other alternatives on the web. One that comes highly recommended (there's even a tag on SO for it) is FlexPaper, an open source plugin that implements a client-side web-based PDF viewer - which I think will suit your needs perfectly (from here):
This project provides a light weight document viewer component
enabling PDF files to be viewed without having any PDF reader software
installed. This project provides both Flex library and stand-alone web
version.
Here are some demos of it in action:
http://flexpaper.devaldi.com/demo/
Sorry, by mistake posted partial comment. Anyway...
Why do you afraid of reuploading of your files ? Put links to original site into the PDF and get profit of this. More copies, more downloads, more popularity for your resource. If you indeed would like to make PDFs available from your site only, you have to hide files from users and provide some functionality to read them from your web site only (you can use existing sites of this type). That makes duplicating of your resources to be harder task, but be ready that many users reject to read it this way.

Web-app deployment and multiple versions [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed last month.
Improve this question
I'm curious to know how other developers deal with versioning of web-apps and deploying different versions. The fundamental problem is that someone might be using your web-app when you deploy a new version, at which point the Javascript etc they have not he client-side is out of date.
Versioning the media on the client-side is easy enough, but if you version that you also need to version your business logic and the database, which is where things could get messy...
So I see a couple of ways of dealing with this:
Display a "Upgrading" notice on the site when deploying a new version.
Version tag client-side and reject any submissions to the new version from old client-side sources. Fair enough, but it doesn't really go hand in hand with continuous deployment.
Continuous DB migration - running multiple version of the app at the same time (migrating users to the new version when possible). This would need any updates on the old DB schema to be "forward ported" to the new schema. Seems the most attractive for deployment, but also could be horribly complex.
Somewhere in the middle of all three.
I should note that I know worrying about this kind of thing is beyond the needs of most apps, but I was thinking about it and I'm curious to know how others deal with it.
This is really an amazing question.
Most important and effective tool is Git that is currently used for versioning tool though there are many tools but I found git the most efficient as it tracks the working of every employee.We can also took suggestions from public contributors for testing purpose. We can make different branches from main that help us to keep our code present in all versions with or without new features. And auto deployment is not a positive step you should test that several times and use different test cases for that.
There are plenty of tools available for your exact requirements. Like Phing, and Phingistrano. Git also makes it simple but that wont display offline notice and DB deployment . I recommend dont go for auto deployment on live server, use auto deployment on staging and manual deployment on live. Also look for continuous integration on google and try teamcity

Serverside Technologies and Flow [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Questions asking us to recommend or find a tool, library or favorite off-site resource are off-topic for Stack Overflow as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it.
Closed 8 years ago.
Improve this question
I'm relatively new to the web development scene, so please excuse any frustratingly obvious questions.
What I've found myself to struggle with is understanding how all the different technologies of web design fit together - how they all fit into the flow of development and their heirarchy.
I understand the basic html,css,javascript flow. HTML defines your structure and content, CSS comes in and then defines the presentation of said content, and finally javascript adds a layer of interaction and defines how the website behaves. Given that, it's easy for me to see how jQuery etc fit into the picture.
As I move towards making more dynamic sites though, I find myself inundated with trying to learn/balance many web technologies and frameworks (django, mysql, sql, innodb, drupal, rails, php, wordpress etc, etc). I realize that some of what i just listed overlap and serve the same function, but that just goes to show my general confusion with the topic. For example, the django example: I understand django is a web framework that runs on python to help you develop web apps quickly, however, the relationship between the server, html, and python is cloudy to me.
Does anyone know of a good source that can outline how all these puzzle pieces fit together (or feel like offering their description of such matters)?
Thanks :-)
I don't know of any resources that explains this the way you're looking for so I'll just add my take. Maybe we can see where I've goofed.
I like to split the technologies into two camps, Client Side and Server Side.
Client Side is anything that runs on or in the web browser on a user's computer, tablet, smartphone, etc. These technologies include:
HTML (for structure)
CSS (for designing the structure)
JavaScript (for making the structure do stuff)
Server Side is anything that requires a connection to a web server and resources on said machine. This may be a web server running on your localhost as a development machine or a server connected to the Internet. These technologies include:
Web server (Apache, nginx, ...) This is what the user actually connects to via www.example.com in their browser
Server Side Language (PHP, python, ruby, ASP.net, ...) This is what provides access to a physical data storage, like a...
Database (MySQL, SQLite, PostgreSql, MongoDB, ...) This is where the data about your website or app is stored
So, in your example a user would connect to a web server, access a file holding a python script that connects to the site's database and then produces the appropriate HTML, CSS and JavaScript to generate a webpage on the browser's screen.
Obviously this is overly simplified and there's a lot more that goes into it but this is it in a general nutshell.
I would also definitely read this post a lot.

How do database driven blog-style websites work? [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 5 years ago.
Improve this question
Before I start: I know this is a very broad question, but it is the best way I could phrase it, I have searched around a lot and can only seem to find generic explanations. I searched SO and didn't find much. I have also skimmed through some pages in the wordpress codex, and didn't find anything really useful.
I would like to create a simple database driven blog-style website, it will really only consist of stories (their title, date, content, etc), I just began teaching myself web development and my idea of how database driven websites work has proven to be completely wrong. I figured you would always need a file connecting to the database for each article, but the more I read I learn about mark up being generated on request, and so on, so the actual /year/month/day/article doesn't actually have to exist on the server, or that may be wrong, that is why I am here.
As I said I cannot find much on this topic that isn't a generic graphic of a server interacting with a web page. How does one go about creating a database driven website of this style? Are the files/directories not actually on the server but only created on a case by case basis as someone requests it? If so, then why can you type out a complete url and it be there with out throwing a 404? I have a lot of questions, really all I need is a strong explanation of how these sites work, code examples, and so on. Could someone explain how they work or point me to information (recommended articles, examples or books)?
EDIT: Please don't recommend a framework, I want to understand how these sites work and build one myself.
It's actually quite simple. Wordpress's index page calls wp-blog-header.php. That file calls for other files, and those files call for other files. It goes on for some time until all the contents of the page are actually loaded.
The databases come in when you start thinking about having users. Obviously the user information is stored in the database. Beyond that, Wordpress keeps post titles, dates, and other information in the database for easy loading later on.
Comments are also stored in the database. Each comment is associated with a number, and in the database, just like the posts, the dates/times as well as the usernames associated with the comments are kept.
Further exploration in the actual Wordpress files will reveal a lot of interesting features.
You might want to check out Django. It is an open source Python web framework that provides a lot of the functionality you are talking about. It also has a lot of very good high-level documentation with even a free e-book. It is centered a bit more on newspaper type sites than blogging, but most of the same principles apply. If you are new to python and like to use IDEs I would recommend checking out PyCharm. It has tight Django integration and makes for simple project setup and debugging.
Generally speaking, you'll use a framework that will take input parameters (year/month/day/article), run some code to fetch data from the database, and dynamically create the webpage. There isn't an actual .html file sitting on the webserver. One of the most popular frameworks to do websites like you're describing is Ruby on Rails, which makes it incredibly simple to do.

Free forum software with a good spam protection [closed]

Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 12 years ago.
Improve this question
About a week ago I had to pull the plug on my PhpBB forums because spam had reached totally unmanageable levels:
The database contained well over 300,000 spam topics & messages, for a total of 8 Gb of junk. None of it was displayed on the website, as the forum was on a strict moderation queue, so there was no point to it, but the volume was such that moderation was plain impossible.
Now, I am considering my options for a new forum.
My requirements are:
PHP or easy to install on a typical
LAMP hosting Free Really good spam protection.
Easy to customize & integrate in my website
Reasonably stable & fast
Easy to manage
PhpBB was good, but the SPAM problem was so bad that the forum never had a chance to really get anywhere.
I have been looking around at similar questions, but there are very little info regarding the quality of their anti-spam features.
I have added reCAPTCHA to a phpBB forum for user registration and additionally run reCAPTCHA plus a very simple blacklist filter handwritten into the phpBB code on posting attempts from unregistered users, and the spam levels are minimal.
Have you tried punbb? It has good spam and xss protection.
There are a lot of tools to stop spam in and around PhpBB.
Require registration to post
Require email validation to register
Use a CAPTCHA on the registration form
Use Akismet to filter posts coming through (there are a lot of other mods than the one I linked to).
Use moderate-first-post (can't remember if it's built in or an add-on)
But if you're looking for something faster and perhaps a little simpler, PunBB is popular and a fork of it, FluxBB is growing in popularity (since the PunBB brand was bought by "the man").
They are a lot faster and lighter on resources but you do trade in quite a lot of community resources, plugins, and built-in features for that.
I implemented FluxBB in a client's site, as viewable here just to show you that it can be fairly tightly integrated into a site's design. In this case the main site is a Wordpress install.
Just noticed your comment on your opening post. I don't think there are any plug-ins, importers or anything really that will automatically cut down existing spam.
Most spam is very similar. Unless you've been targeted by multiple spammers, you might be able to write a little PHP script to look for known spam signatures and delete them (and their users) automatically.
This should get you back to a point where you can manually moderate quite quickly.

Resources