def new
      @page = Humpyard::config.page_types[params[:type]].new
      
      unless can? :create, @page.page
        render :json => {
          :status => :failed
        }, :status => 403
        return
      end
      
      @page_type = params[:type]
      @prev = Humpyard::Page.find_by_id(params[:prev_id])
      @next = Humpyard::Page.find_by_id(params[:next_id])
      
      render :partial => 'edit'
    end
def new
      @page = Humpyard::config.page_types[params[:type]].new
      
      unless can? :create, @page.page
        render :json => {
          :status => :failed
        }, :status => 403
        return
      end
      
      @page_type = params[:type]
      @prev = Humpyard::Page.find_by_id(params[:prev_id])
      @next = Humpyard::Page.find_by_id(params[:next_id])
      
      render :partial => 'edit'
    end
Dialog content for a new page