Put an indeterminate progressbar as footer in a RecyclerView grid

It is very simple to do that. The solution is to use the same approach of the LinearLayoutManager with a GridLayoutManager and then use the method setSpanSizeLookup on the LayoutManager like this: mLayoutManager.setSpanSizeLookup(new GridLayoutManager.SpanSizeLookup() { @Override public int getSpanSize(int position) { switch(myAdapter.getItemViewType(position)){ case MyAdapter.VIEW_TYPES.Product: return 1; case MyAdapter.VIEW_TYPES.Progress: return 2; //number of columns of the … Read more

Creating templated/persistant header/footer template in jQuery Mobile and PhoneGap

I’ve been trying to tackle this problem for a few days now and I’ve gotten really close to the solution. I use the following HTML: <body> <div data-role=”page” id=”page”> <div data-role=”header”> <h1 id=”title”>Title</h1> </div><!– /header –> <div data-role=”content” id=”content”> <p>Loading…</p> </div><!– /content –> <div data-role=”footer” id=”footer” data-position=”fixed”> <div data-role=”navbar” id=”navbar”> </div> </div><!– /footer –> </div><!– … Read more

RecyclerView header and footer

in your adapter add this class: private class VIEW_TYPES { public static final int Header = 1; public static final int Normal = 2; public static final int Footer = 3; } then Override the following method like this: @Override public int getItemViewType(int position) { if(items.get(position).isHeader) return VIEW_TYPES.Header; else if(items.get(position).isFooter) return VIEW_TYPES.Footer; else return VIEW_TYPES.Normal; … Read more

Fix footer to bottom of page

For your footer: #footer { position: fixed; height: 50px; background-color: red; bottom: 0px; left: 0px; right: 0px; margin-bottom: 0px; } For your body: body { margin-bottom:50px; } #footer { background-color: red; position: fixed; bottom: 0px; left: 0px; right: 0px; height: 50px; margin-bottom: 0px; } div { margin: 20px 20px; } body { margin-bottom: 50px; } … Read more

How to add a footer in ListView?

Create a footer view layout consisting of text that you want to set as footer and then try View footerView = ((LayoutInflater) ActivityContext.getSystemService(Context.LAYOUT_INFLATER_SERVICE)).inflate(R.layout.footer_layout, null, false); ListView.addFooterView(footerView); Layout for footer could be something like this: <?xml version=”1.0″ encoding=”utf-8″?> <LinearLayout xmlns:android=”http://schemas.android.com/apk/res/android” android:layout_width=”wrap_content” android:layout_height=”wrap_content” android:paddingTop=”7dip” android:paddingBottom=”7dip” android:orientation=”horizontal” android:gravity=”center”> <LinearLayout android:id=”@+id/footer_layout” android:layout_width=”wrap_content” android:layout_height=”wrap_content” android:orientation=”horizontal” android:gravity=”center” android:layout_gravity=”center”> <TextView android:text=”@string/footer_text_1″ android:id=”@+id/footer_1″ … Read more

Fixed footer in Bootstrap

To get a footer that sticks to the bottom of your viewport, give it a fixed position like this: footer { position: fixed; height: 100px; bottom: 0; width: 100%; } Bootstrap includes this CSS in the Navbar > Placement section with the class fixed-bottom. Just add this class to your footer element: <footer class=”fixed-bottom”> Bootstrap … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)