Index of the webhelpers module
-
m
webhelpers
...
- a javascript_path ...
- a javascript_builtins ...
-
m
util
...
- Utility functions used by various web helpers
- C Partial ... - partial object, which will be in Python 2.5
-
C
UnicodeMultiDict
...
- A MultiDict wrapper that decodes returned values to unicode on the
fly. Decoding is not applied to assigned values.
- f popitem ...
- f pop ...
- f has_key ...
- f __init__ ...
- f __contains__ ...
- f getall ... - Return a list of all values matching the key (may be an empty list)
- f add ... - Add the key and value, not overwriting any previous value.
- f itervalues ...
- f dict_of_lists ... - Returns a dictionary where each key is associated with a list of values.
- f __len__ ...
- f __getitem__ ...
- f keys ...
- f __setitem__ ...
- f iteritems ...
- f copy ...
- f iterkeys ...
- f __delitem__ ...
- f setdefault ...
- f items ...
- f clear ...
- f __iter__ ...
- f values ...
- f getone ... - Get one value matching the key, raising a KeyError if multiple values were found.
- f mixed ... - Returns a dictionary where the values are either single values, or a list of values when a key/value appears more than once in this dictionary. This is similar to the kind of dictionary often used to represent the variables in a web request.
-
C
SimplerXMLGenerator
...
- f addQuickElement ... - Convenience method for adding an element with no children
- f html_escape ... - HTML-escape a string or object
- m commands ...
-
m
feedgenerator
...
- Syndication feed generation library -- used for generating RSS, etc.
- C Atom1Feed ...
-
C
RssUserland091Feed
...
- a mime_type ...
- f num_items ...
- f latest_post_date ... - Returns the latest item's pubdate.
- f write_items ...
- f writeString ... - Returns the feed in the given encoding as a string.
- f write ...
- f add_item ... - Adds an item to the feed.
- f __init__ ...
- f endChannelElement ...
-
C
DefaultFeed
...
- f num_items ...
- f latest_post_date ... - Returns the latest item's pubdate.
- f write_items ...
- f writeString ... - Returns the feed in the given encoding as a string.
- f write ...
- f add_item ... - Adds an item to the feed.
- f __init__ ...
- f endChannelElement ...
- C SyndicationFeed ... - Base class for all syndication feeds. Subclasses should provide write()
-
C
RssFeed
...
- f num_items ...
- f endChannelElement ...
- f writeString ... - Returns the feed in the given encoding as a string.
- f write ...
- f add_item ... - Adds an item to the feed.
- f __init__ ...
- f latest_post_date ... - Returns the latest item's pubdate.
- C Enclosure ... - Represents an RSS enclosure
- f rfc3339_date ...
- f rfc2822_date ...
- f get_tag_uri ... - Creates a TagURI. See http://diveintomark.org/archives/2004/05/28/howto-atom-id
-
m
rails
...
- Helper functions ported from Rails
-
m
text
...
- Text Helpers
- f reset_cycle ... - Resets a cycle
- f markdown ... - Format the text with MarkDown formatting
- f strip_links ... - Strips link tags from text leaving just the link label.
- f excerpt ... - Extracts an excerpt from the text. Returns an empty string if the phrase isn't found.
- f textilize ... - Format the text with Textile formatting
- f reset_counter ... - Resets a counter.
- f simple_format ... - Returns text transformed into HTML using very simple formatting rules
- f word_wrap ... - Wraps text into lines no longer than line_width width. This function breaks on the first whitespace character that does not exceed line_width.
- f auto_link ... - Turns all urls and email addresses into clickable links.
- f truncate ... - Truncates text with replacement characters
- f cycle ... - Returns the next cycle of the given list
- f counter ... - Return the next cardinal in a sequence.
- f highlight ... - Highlights the phrase where it is found in the text
-
m
form_tag
...
- Form Tag Helpers
- f form ... - Starts a form tag that points the action to an url.
- f password_field ... - Creates a password field
- f text_area ... - Creates a text input area.
- f submit ... - Creates a submit button with the text value as the caption.
- f end_form ... - Outputs "</form>"
- f hidden_field ... - Creates a hidden field.
- f text_field ... - Creates a standard text field.
- f radio_button ... - Creates a radio button.
- f file_field ... - Creates a file upload field.
- f select ... - Creates a dropdown selection box
- f check_box ... - Creates a check box.
-
m
scriptaculous
...
- Scriptaculous Helpers
- f sortable_element ... - Makes the element with the DOM ID specified by element_id sortable.
- f parallel_effects ... - Wraps visual effects so they occur in parallel
- f drop_receiving_element ... - Makes an element able to recieve dropped draggable elements
- f draggable_element ... - Makes the element with the DOM ID specified by element_id draggable.
- f visual_effect ... - Returns a JavaScript snippet to be used on the Ajax callbacks for starting visual effects.
-
m
asset_tag
...
- Asset Tag Helpers
- f auto_discovery_link_tag ... - Returns a link tag allowing browsers and news readers (that support it) to auto-detect an RSS or ATOM feed for current page.
- f javascript_include_tag ... - Returns script include tags for the specified javascript sources.
- f image_tag ... - Returns an image tag for the specified source.
- f stylesheet_link_tag ... - Returns CSS link tags for the specified stylesheet sources.
-
m
javascript
...
- Javascript Helpers
- f button_to_function ... - Returns a link that'll trigger a JavaScript function using the onclick handler and return false after the fact.
- f javascript_tag ... - Returns a JavaScript tag with the content inside.
- f escape_javascript ... - Escape carriage returns and single and double quotes for JavaScript segments.
- f link_to_function ... - Returns a link that'll trigger a JavaScript function using the onclick handler and return false after the fact.
-
m
tags
...
- Tag Helpers
- f content_tag ... - Create a tag with content
- f escape_once ... - Escapes a given string without affecting existing escaped entities.
- f camelize ... - Camelize a name
- f cdata_section ... - Returns a CDATA section with the given content.
- f tag ... - Returns an XHTML compliant tag of type name.
-
m
urls
...
- URL Helpers
- f link_to_unless ... - Conditionally create a link tag of the given name using the url
- f button_to ... - Generates a form containing a sole button that submits to the URL given by url.
- f link_to ... - Creates a link tag of the given name using an URL created by the set of options.
- f link_to_unless_current ... - Conditionally create a link tag of the given name using the url
- f link_to_if ... - Conditionally create a link tag of the given name using the url
- f js_obfuscate ... - Obfuscates data in a Javascript tag
- f mail_to ... - Creates a link tag for starting an email to the specified email_address, which is also used as the name of the link unless name is specified. Additional HTML options, such as class or id, can be passed in the html_options hash.
- f current_url ... - Returns the current page's url.
- f url ... - Lazily evaluates url_for() arguments
- f current_page ... - Returns true if the current page uri is equivalent to url
-
m
number
...
- Number Helpers
- f human_size ... - Deprecated: Use number_to_human_size instead.
- f number_to_phone ... - Formats a number into a US phone number string.
- f number_to_human_size ... - Returns a formatted-for-humans file size.
- f number_with_delimiter ... - Formats a number with grouped thousands using delimiter.
- f number_to_percentage ... - Formats a number as into a percentage string.
- f number_with_precision ... - Formats a number with a level of precision.
- f number_to_currency ... - Formats a number into a currency string.
-
m
prototype
...
- Prototype Helpers
- f submit_to_remote ... - A submit button that submits via an XMLHttpRequest call
- f update_element_function ... - Returns a JavaScript function (or expression) that'll update a DOM element.
- f remote_function ... - Returns the JavaScript needed for a remote function.
- f form_remote_tag ... - Create a form tag using a remote function to submit the request
- f observe_field ... - Observes the field with the DOM ID specified by field_id and makes an Ajax call when its contents have changed.
- f evaluate_remote_response ... - Returns a Javascript function that evals a request response
- f periodically_call_remote ... - Periodically calls a remote function
- f link_to_remote ... - Links to a remote function
- f observe_form ... - Like observe_field, but operates on an entire form identified by the DOM ID form_id.
-
m
secure_form_tag
...
- Secure Form Tag Helpers -- For prevention of Cross-site request forgery (CSRF)
attacks.
- f secure_form_remote_tag ... - Create a form tag (like webhelpers.rails.prototype.form_remote_tag) including a hidden authentication token field.
- f secure_form ... - Create a form tag (like webhelpers.rails.form_tag.form) including a hidden authentication token field.
-
m
date
...
- Date/Time Helpers
- f time_ago_in_words ... - Like distance_of_time_in_words, but where to_time is fixed to datetime.now().
- f distance_of_time_in_words ... - Reports the approximate distance in time between two datetime objects or integers as seconds.
-
m
form_options
...
- Form Options Helpers
- f options_for_select_from_dicts ... - Create select options from dicts in a container
- f options_for_select ... - Creates select options from a container (list, tuple, dict)
- f options_for_select_from_objects ... - Create select options from objects in a container
-
m
text
...
- Text Helpers
-
m
pagination
...
- Pagination for Collections and ORMs
- a find_page ...
- C Paginator ... - Tracks paginated sets of data, and supplies common pagination operations
- C Window ... - Represents ranges around a given page.
-
C
Page
...
- Represents a single page from a paginated set.
- a last ... - Boolean indicating if this page is the last.
- a first_item ... - The number of the first item in the page.
- a last_item ... - The number of the last item in the page.
- a offset ... - Offset of the page, useful for database queries.
- a previous ... - Previous page if it exists, None otherwise.
- a next ... - Next page if it exists, None otherwise.
- a first ... - Boolean indiciating if this page is the first.
- f __int__ ...
- f __cmp__ ...
- f window ...
- f __eq__ ...
- f __init__ ... - Creates a new Page for the given paginator with the index number.
- f paginate ... - Paginate a collection of data
- m links ... - Pagination Link Generators
-
m
orm
...
- ORM Wrappers
- a orms ...
-
C
SQLAlchemyLazyTable
...
- f __len__ ...
- f __getitem__ ...
-
C
SQLAlchemyLazyMapper
...
- f __len__ ...
- f __getitem__ ...
-
C
SQLObjectLazy
...
- f __len__ ...
- f __getitem__ ...
-
C
SQLAlchemy04LazySessionMapper
...
- f __len__ ...
- f __getitem__ ...
-
C
SQLAlchemy04LazyMapper
...
- f __len__ ...
- f __getitem__ ...
- f get_wrapper ...
-
m
htmlgen
...
- htmlgen
-
m
textile
...
- This is Textile
A Humane Web Text Generator
- a ENCODING ...
- a HEAD_OFFSET ...
- a res ...
- a htmlizer ...
- a AMAZON ...
- a __authors__ ...
- a parameters ...
- a __history__ ...
- a OUTPUT ...
-
C
Textiler
...
- Textile formatter.
- f pre ... - Process pre-formatted text.
- f links ... - Process links.
- f footnote ... - Process a footnote.
- f image ... - Process each image.
- f header ... - Process a header.
- f escape ... - Do nothing.
- f images ... - Process images.
- f table ... - Build a table.
- f process ... - Process the text.
- f __init__ ... - Instantiate the class, passing the text to be formatted.
- f qtags ... - Quick tags formatting.
- f split_text ... - Process the blocks from the text.
- f format ... - Text formatting.
- f macros ... - Quick macros.
- f sanitize ... - Fix single tags.
- f build_open_tag ... - Build the open tag with specified attributes.
- f grab_links ... - Grab link lookups.
- f glyphs ... - Glyph formatting.
- f dl ... - Process definition list.
- f blockquote ... - Process block quote.
- f bc ... - Process block code.
- f acronym ... - Process acronyms.
- f build_li ... - Build the list item.
- f preprocess ... - Pre-processing of the text.
- f parse_params ... - Parse the parameters from a block signature.
- f about ... - Show PyTextile's functionalities.
- f ol ... - Build an ordered list.
- f itex ... - Convert itex to MathML.
- f ul ... - Build an unordered list.
- f paragraph ... - Process a paragraph.
- f inline ... - Inline formatting.
- f footnotes ... - Add titles to footnotes references.
- f html_replace ... - Replacement outside HTML tags.
- f textile ... - This is Textile.
- f preg_replace ... - Alternative re.sub that handles empty groups.
- m hinclude ... - Tired of regenerating HTML pages from templates? Want more from Web caches? HInclude makes one thing very easy; including other bits of HTML into your Web page, using the browser.