Moved indexing script to the view in contentbase.py